Class: MendixBridge::Model::Entity

Inherits:
Data
  • Object
show all
Defined in:
lib/mendix_bridge/model.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#access_rulesObject (readonly)

Returns the value of attribute access_rules

Returns:

  • (Object)

    the current value of access_rules



30
31
32
# File 'lib/mendix_bridge/model.rb', line 30

def access_rules
  @access_rules
end

#associationsObject (readonly)

Returns the value of attribute associations

Returns:

  • (Object)

    the current value of associations



30
31
32
# File 'lib/mendix_bridge/model.rb', line 30

def associations
  @associations
end

#attributesObject (readonly)

Returns the value of attribute attributes

Returns:

  • (Object)

    the current value of attributes



30
31
32
# File 'lib/mendix_bridge/model.rb', line 30

def attributes
  @attributes
end

#nameObject (readonly)

Returns the value of attribute name

Returns:

  • (Object)

    the current value of name



30
31
32
# File 'lib/mendix_bridge/model.rb', line 30

def name
  @name
end

#persistableObject (readonly)

Returns the value of attribute persistable

Returns:

  • (Object)

    the current value of persistable



30
31
32
# File 'lib/mendix_bridge/model.rb', line 30

def persistable
  @persistable
end

Instance Method Details

#to_hObject



37
38
39
40
41
42
43
44
45
# File 'lib/mendix_bridge/model.rb', line 37

def to_h
  {
    name:,
    persistable:,
    attributes: attributes.map(&:to_h),
    associations: associations.map(&:to_h),
    access_rules: access_rules.map(&:to_h)
  }
end