Class: SSHCredential

Inherits:
Object
  • Object
show all
Includes:
Thrift::Struct, Thrift::Struct_Union
Defined in:
lib/credential_store_data_models_types.rb

Constant Summary collapse

GATEWAYID =
1
USERNAME =
2
PASSPHRASE =
3
PUBLICKEY =
4
PRIVATEKEY =
5
PERSISTEDTIME =
6
TOKEN =
7
DESCRIPTION =
8
FIELDS =
{
  GATEWAYID => {:type => ::Thrift::Types::STRING, :name => 'gatewayId'},
  USERNAME => {:type => ::Thrift::Types::STRING, :name => 'username'},
  PASSPHRASE => {:type => ::Thrift::Types::STRING, :name => 'passphrase', :optional => true},
  PUBLICKEY => {:type => ::Thrift::Types::STRING, :name => 'publicKey', :optional => true},
  PRIVATEKEY => {:type => ::Thrift::Types::STRING, :name => 'privateKey', :optional => true},
  PERSISTEDTIME => {:type => ::Thrift::Types::I64, :name => 'persistedTime', :optional => true},
  TOKEN => {:type => ::Thrift::Types::STRING, :name => 'token', :optional => true},
  DESCRIPTION => {:type => ::Thrift::Types::STRING, :name => 'description', :optional => true}
}

Instance Method Summary collapse

Instance Method Details

#struct_fieldsObject



39
# File 'lib/credential_store_data_models_types.rb', line 39

def struct_fields; FIELDS; end

#validateObject

Raises:

  • (::Thrift::ProtocolException)


41
42
43
44
# File 'lib/credential_store_data_models_types.rb', line 41

def validate
  raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field gatewayId is unset!') unless @gatewayId
  raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field username is unset!') unless @username
end