class PlaceOS::Model::LdapAuthentication
- PlaceOS::Model::LdapAuthentication
- PlaceOS::Model::ModelBase
- RethinkORM::Base
- ActiveModel::Model
- Reference
- Object
Overview
see: https://github.com/omniauth/omniauth-ldap
Included Modules
- RethinkORM::Timestamps
Defined in:
placeos-models/ldap_authentication.crConstant Summary
-
CALLBACKS =
{before_save: [] of Nil, after_save: [] of Nil, before_create: [do self.created_at = self.updated_at = Time.utc end] of Nil, after_create: [] of Nil, before_update: [do self.updated_at = Time.utc end] of Nil, after_update: [] of Nil, before_destroy: [] of Nil, after_destroy: [] of Nil}
-
see: https://github.com/omniauth/omniauth-ldap
-
Log =
::Log.for(self)
-
see: https://github.com/omniauth/omniauth-ldap
Constructors
-
.from_trusted_json(string_or_io : String | IO) : self
Serialize from a trusted JSON source
-
.from_trusted_yaml(string_or_io : String | IO) : self
Serialize from a trusted YAML source
-
.new(ctx : YAML::ParseContext, node : YAML::Nodes::Node)
see: https://github.com/omniauth/omniauth-ldap
-
.new(created_at : Time | Nil = nil, updated_at : Time | Nil = nil, name : String | Nil = nil, port : Int32 | Nil = nil, auth_method : String | Nil = nil, uid : String | Nil = nil, host : String | Nil = nil, base : String | Nil = nil, bind_dn : String | Nil | Nil = nil, password : String | Nil | Nil = nil, filter : String | Nil | Nil = nil, authority_id : String | Nil | Nil = nil, id : String | Nil | Nil = nil)
see: https://github.com/omniauth/omniauth-ldap
-
.new(params : HTTP::Params | Hash(String, String) | Tuple(String, String))
Initialize PlaceOS::Model::LdapAuthentication from
HTTP::Params
.
Class Method Summary
-
.attributes : Array(Symbol)
Returns all attribute keys.
-
.by_authority_id(id)
Look up instances of this model dependent on the foreign key
-
.elastic
see: https://github.com/omniauth/omniauth-ldap
-
.table_name
see: https://github.com/omniauth/omniauth-ldap
Instance Method Summary
- #__authority : Authority | Nil
- #__authority=(__authority : Authority | Nil)
-
#after_create
see: https://github.com/omniauth/omniauth-ldap
-
#after_destroy
see: https://github.com/omniauth/omniauth-ldap
-
#after_save
see: https://github.com/omniauth/omniauth-ldap
-
#after_update
see: https://github.com/omniauth/omniauth-ldap
-
#apply_defaults
Generate code to apply default values
-
#assign_attributes(created_at : Time | Missing = Missing, updated_at : Time | Missing = Missing, name : String | Missing = Missing, port : Int32 | Missing = Missing, auth_method : String | Missing = Missing, uid : String | Missing = Missing, host : String | Missing = Missing, base : String | Missing = Missing, bind_dn : String | Nil | Missing = Missing, password : String | Nil | Missing = Missing, filter : String | Nil | Missing = Missing, authority_id : String | Nil | Missing = Missing, id : String | Nil | Missing = Missing)
Assign to multiple attributes.
-
#assign_attributes(params : HTTP::Params | Hash(String, String) | Tuple(String, String))
Assign to mulitple attributes via
HTTP::Params
. -
#assign_attributes_from_json(json)
see: https://github.com/omniauth/omniauth-ldap
-
#assign_attributes_from_trusted_json(json)
see: https://github.com/omniauth/omniauth-ldap
-
#assign_attributes_from_trusted_yaml(yaml)
see: https://github.com/omniauth/omniauth-ldap
-
#assign_attributes_from_yaml(yaml)
Uses the YAML parser as JSON is valid YAML
-
#attributes
Returns a
Hash
of all attribute values -
#attributes_tuple
Returns a
NamedTuple
of all attribute values. -
#auth_method : String
#auth_method
getter -
#auth_method=(value : String)
#auth_method
setter -
#auth_method_change
Returns
{ auth_method_was, auth_method }
if#auth_method
has changed. -
#auth_method_changed?
Check if
#auth_method
is in the set of changed attributes. -
#auth_method_default : String
#auth_method
's default value -
#auth_method_was : String?
Returns the previous value of
#auth_method
. -
#auth_method_will_change!
Include
#auth_method
in the set of changed attributes, whether it has changed or not. -
#authority : Authority | Nil
Retrieves the parent relationship
- #authority! : Authority
-
#authority=(parent : Authority)
Sets the parent relationship
-
#authority_id : String | Nil
#authority_id
getter -
#authority_id=(value : String | Nil)
#authority_id
setter -
#authority_id_change
Returns
{ authority_id_was, authority_id }
if#authority_id
has changed. -
#authority_id_changed?
Check if
#authority_id
is in the set of changed attributes. -
#authority_id_default : String | Nil
#authority_id
's default value -
#authority_id_was : String?
Returns the previous value of
#authority_id
. -
#authority_id_will_change!
Include
#authority_id
in the set of changed attributes, whether it has changed or not. -
#base : String
#base
getter -
#base=(value : String)
#base
setter -
#base_change
Returns
{ base_was, base }
if#base
has changed. -
#base_changed?
Check if
#base
is in the set of changed attributes. -
#base_default : String
#base
's default value -
#base_was : String?
Returns the previous value of
#base
. -
#base_will_change!
Include
#base
in the set of changed attributes, whether it has changed or not. -
#before_create
see: https://github.com/omniauth/omniauth-ldap
-
#before_destroy
see: https://github.com/omniauth/omniauth-ldap
-
#before_save
see: https://github.com/omniauth/omniauth-ldap
-
#before_update
see: https://github.com/omniauth/omniauth-ldap
-
#bind_dn : String | Nil
#bind_dn
getter -
#bind_dn=(value : String | Nil)
#bind_dn
setter -
#bind_dn_change
Returns
{ bind_dn_was, bind_dn }
if#bind_dn
has changed. -
#bind_dn_changed?
Check if
#bind_dn
is in the set of changed attributes. -
#bind_dn_default : String | Nil
#bind_dn
's default value -
#bind_dn_was : String?
Returns the previous value of
#bind_dn
. -
#bind_dn_will_change!
Include
#bind_dn
in the set of changed attributes, whether it has changed or not. -
#changed?
Check if any attributes have changed.
-
#changed_attributes
Returns a
Hash
with all changed attributes. -
#changed_json(io : IO) : Nil
Serialize the set of changed attributes to JSON.
-
#changed_json : String
Serialize the set of changed attributes to JSON.
-
#changed_yaml(io : IO) : Nil
Serialize the set of changed attributes to YAML.
-
#changed_yaml : String
Serialize the set of changed attributes to YAML.
-
#clear_changes_information
Reset changes for all attributes.
-
#created_at : Time
#created_at
getter -
#created_at=(value : Time)
Override the map json
#created_at
setter -
#created_at_change
Returns
{ created_at_was, created_at }
if#created_at
has changed. -
#created_at_changed?
Check if
#created_at
is in the set of changed attributes. -
#created_at_default : Time
#created_at
's default value -
#created_at_was : Time?
Returns the previous value of
#created_at
. -
#created_at_will_change!
Include
#created_at
in the set of changed attributes, whether it has changed or not. -
#filter : String | Nil
#filter
getter -
#filter=(value : String | Nil)
#filter
setter -
#filter_change
Returns
{ filter_was, filter }
if#filter
has changed. -
#filter_changed?
Check if
#filter
is in the set of changed attributes. -
#filter_default : String | Nil
#filter
's default value -
#filter_was : String?
Returns the previous value of
#filter
. -
#filter_will_change!
Include
#filter
in the set of changed attributes, whether it has changed or not. -
#host : String
#host
getter -
#host=(value : String)
#host
setter -
#host_change
Returns
{ host_was, host }
if#host
has changed. -
#host_changed?
Check if
#host
is in the set of changed attributes. -
#host_default : String
#host
's default value -
#host_was : String?
Returns the previous value of
#host
. -
#host_will_change!
Include
#host
in the set of changed attributes, whether it has changed or not. -
#id : String | Nil
#id
getter -
#id=(value : String | Nil)
#id
setter -
#id_change
Returns
{ id_was, id }
if#id
has changed. -
#id_changed?
Check if
#id
is in the set of changed attributes. -
#id_was : String?
Returns the previous value of
#id
. -
#id_will_change!
Include
#id
in the set of changed attributes, whether it has changed or not. -
#name : String
#name
getter -
#name=(value : String)
#name
setter -
#name_change
Returns
{ name_was, name }
if#name
has changed. -
#name_changed?
Check if
#name
is in the set of changed attributes. -
#name_default : String
#name
's default value -
#name_was : String?
Returns the previous value of
#name
. -
#name_will_change!
Include
#name
in the set of changed attributes, whether it has changed or not. -
#password : String | Nil
#password
getter -
#password=(value : String | Nil)
#password
setter -
#password_change
Returns
{ password_was, password }
if#password
has changed. -
#password_changed?
Check if
#password
is in the set of changed attributes. -
#password_default : String | Nil
#password
's default value -
#password_was : String?
Returns the previous value of
#password
. -
#password_will_change!
Include
#password
in the set of changed attributes, whether it has changed or not. -
#persistent_attributes
Returns a
Hash
of all attributes that can be persisted. -
#port : Int32
#port
getter -
#port=(value : Int32)
#port
setter -
#port_change
Returns
{ port_was, port }
if#port
has changed. -
#port_changed?
Check if
#port
is in the set of changed attributes. -
#port_default : Int32
#port
's default value -
#port_was : Int32?
Returns the previous value of
#port
. -
#port_will_change!
Include
#port
in the set of changed attributes, whether it has changed or not. - #reset_associations
-
#restore_attributes
Reset each attribute to their previous values and clears all changes.
-
#run_create_callbacks(&)
Wrap a block with callbacks for the appropriate crud operation
-
#run_destroy_callbacks(&)
see: https://github.com/omniauth/omniauth-ldap
-
#run_save_callbacks(&)
see: https://github.com/omniauth/omniauth-ldap
-
#run_update_callbacks(&)
see: https://github.com/omniauth/omniauth-ldap
-
#table_name
see: https://github.com/omniauth/omniauth-ldap
-
#to_json(json : JSON::Builder)
see: https://github.com/omniauth/omniauth-ldap
-
#to_yaml(__temp_431 : YAML::Nodes::Builder)
see: https://github.com/omniauth/omniauth-ldap
-
#uid : String
#uid
getter -
#uid=(value : String)
#uid
setter -
#uid_change
Returns
{ uid_was, uid }
if#uid
has changed. -
#uid_changed?
Check if
#uid
is in the set of changed attributes. -
#uid_default : String
#uid
's default value -
#uid_was : String?
Returns the previous value of
#uid
. -
#uid_will_change!
Include
#uid
in the set of changed attributes, whether it has changed or not. -
#updated_at : Time
#updated_at
getter -
#updated_at=(value : Time)
#updated_at
setter -
#updated_at_change
Returns
{ updated_at_was, updated_at }
if#updated_at
has changed. -
#updated_at_changed?
Check if
#updated_at
is in the set of changed attributes. -
#updated_at_default : Time
#updated_at
's default value -
#updated_at_was : Time?
Returns the previous value of
#updated_at
. -
#updated_at_will_change!
Include
#updated_at
in the set of changed attributes, whether it has changed or not. -
#validate_nilability
Validate that all non-nillable fields have values.
Instance methods inherited from class PlaceOS::Model::ModelBase
after_create
after_create,
after_destroy
after_destroy,
after_save
after_save,
after_update
after_update,
apply_defaults
apply_defaults,
assign_attributes(id : String | Nil | Missing = Missing)assign_attributes(params : HTTP::Params | Hash(String, String) | Tuple(String, String)) assign_attributes, attributes attributes, attributes_tuple attributes_tuple, before_create before_create, before_destroy before_destroy, before_save before_save, before_update before_update, persistent_attributes persistent_attributes, run_create_callbacks(&) run_create_callbacks, run_destroy_callbacks(&) run_destroy_callbacks, run_save_callbacks(&) run_save_callbacks, run_update_callbacks(&) run_update_callbacks
Class methods inherited from class PlaceOS::Model::ModelBase
attributes : Array(Symbol)
attributes
Constructor Detail
Serialize from a trusted JSON source
Serialize from a trusted YAML source
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Initialize PlaceOS::Model::LdapAuthentication from HTTP::Params
.
Class Method Detail
Instance Method Detail
Assign to multiple attributes.
Assign to mulitple attributes via HTTP::Params
.
Include #auth_method
in the set of changed attributes, whether it has changed or not.
Include #authority_id
in the set of changed attributes, whether it has changed or not.
Include #base
in the set of changed attributes, whether it has changed or not.
Include #bind_dn
in the set of changed attributes, whether it has changed or not.
Include #created_at
in the set of changed attributes, whether it has changed or not.
Include #filter
in the set of changed attributes, whether it has changed or not.
Include #host
in the set of changed attributes, whether it has changed or not.
Include #name
in the set of changed attributes, whether it has changed or not.
Include #password
in the set of changed attributes, whether it has changed or not.
Include #port
in the set of changed attributes, whether it has changed or not.
Include #uid
in the set of changed attributes, whether it has changed or not.
Include #updated_at
in the set of changed attributes, whether it has changed or not.