Class: LockstepSdk::ApplicationModel

Inherits:
Object
  • Object
show all
Defined in:
lib/lockstep_sdk/models/application_model.rb

Overview

An Application represents a feature available to customers within the Lockstep Platform. You can create Applications by working with your Lockstep business development manager and publish them on the platform so that customers can browse and find your Application on the Lockstep Platform Marketplace. When a customer adds an Application to their account, they obtain an AppEnrollment which represents that customer's instance of this Application. The customer-specific AppEnrollment contains a customer's configuration data for the Application, which is not customer-specific.

See [Applications and Enrollments](developer.lockstep.io/docs/applications-and-enrollments) for more information. –swaggerCategory:Platform

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(params = {}) ⇒ ApplicationModel

Initialize the ApplicationModel using the provided prototype



36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
# File 'lib/lockstep_sdk/models/application_model.rb', line 36

def initialize(params = {})
    @app_id = params.dig(:app_id)
    @name = params.dig(:name)
    @description = params.dig(:description)
    @app_type = params.dig(:app_type)
    @owner_id = params.dig(:owner_id)
    @project_url = params.dig(:project_url)
    @icon_url = params.dig(:icon_url)
    @price_terms = params.dig(:price_terms)
    @created_user_id = params.dig(:created_user_id)
    @modified_user_id = params.dig(:modified_user_id)
    @created = params.dig(:created)
    @modified = params.dig(:modified)
    @is_active = params.dig(:is_active)
    @wiki_url = params.dig(:wiki_url)
    @group_key = params.dig(:group_key)
    @notes = params.dig(:notes)
    @attachments = params.dig(:attachments)
    @custom_field_definitions = params.dig(:custom_field_definitions)
    @custom_field_values = params.dig(:custom_field_values)
end

Instance Attribute Details

#app_idUuid

Returns A unique code identifying this application.

Returns:

  • (Uuid)

    A unique code identifying this application



60
61
62
# File 'lib/lockstep_sdk/models/application_model.rb', line 60

def app_id
  @app_id
end

#app_typeString

Returns Tag for what type of app this is.

Returns:

  • (String)

    Tag for what type of app this is



72
73
74
# File 'lib/lockstep_sdk/models/application_model.rb', line 72

def app_type
  @app_type
end

#attachmentsAttachmentModel

Returns All attachments attached to this app. To retrieve this collection, specify `Attachments` in the “Include” parameter for your query.

Returns:

  • (AttachmentModel)

    All attachments attached to this app. To retrieve this collection, specify `Attachments` in the “Include” parameter for your query.



124
125
126
# File 'lib/lockstep_sdk/models/application_model.rb', line 124

def attachments
  @attachments
end

#createdDate-time

Returns The date this application was created.

Returns:

  • (Date-time)

    The date this application was created



100
101
102
# File 'lib/lockstep_sdk/models/application_model.rb', line 100

def created
  @created
end

#created_user_idUuid

Returns The ID of the user who created this application.

Returns:

  • (Uuid)

    The ID of the user who created this application



92
93
94
# File 'lib/lockstep_sdk/models/application_model.rb', line 92

def created_user_id
  @created_user_id
end

#custom_field_definitionsCustomFieldDefinitionModel

Returns All definitions attached to the application. To retrieve this collection, specify `CustomFieldValues` in the “Include” parameter for your query.

Returns:

  • (CustomFieldDefinitionModel)

    All definitions attached to the application. To retrieve this collection, specify `CustomFieldValues` in the “Include” parameter for your query.



128
129
130
# File 'lib/lockstep_sdk/models/application_model.rb', line 128

def custom_field_definitions
  @custom_field_definitions
end

#custom_field_valuesCustomFieldValueModel

Returns All values attached to the application. To retrieve this collection, specify `CustomFieldValues` in the “Include” parameter for your query.

Returns:

  • (CustomFieldValueModel)

    All values attached to the application. To retrieve this collection, specify `CustomFieldValues` in the “Include” parameter for your query.



132
133
134
# File 'lib/lockstep_sdk/models/application_model.rb', line 132

def custom_field_values
  @custom_field_values
end

#descriptionString

Returns Brief summary of this application shown as a subtitle.

Returns:

  • (String)

    Brief summary of this application shown as a subtitle



68
69
70
# File 'lib/lockstep_sdk/models/application_model.rb', line 68

def description
  @description
end

#group_keyUuid

Returns The GroupKey uniquely identifies a single Lockstep Platform account. All records for this account will share the same GroupKey value. GroupKey values cannot be changed once created. For more information, see [Accounts and GroupKeys](developer.lockstep.io/docs/accounts-and-groupkeys).

Returns:

  • (Uuid)

    The GroupKey uniquely identifies a single Lockstep Platform account. All records for this account will share the same GroupKey value. GroupKey values cannot be changed once created. For more information, see [Accounts and GroupKeys](developer.lockstep.io/docs/accounts-and-groupkeys).



116
117
118
# File 'lib/lockstep_sdk/models/application_model.rb', line 116

def group_key
  @group_key
end

#icon_urlUri

Returns The URL for the icon for this application.

Returns:

  • (Uri)

    The URL for the icon for this application



84
85
86
# File 'lib/lockstep_sdk/models/application_model.rb', line 84

def icon_url
  @icon_url
end

#is_activeBoolean

Returns Flag indicating if the application is active.

Returns:

  • (Boolean)

    Flag indicating if the application is active.



108
109
110
# File 'lib/lockstep_sdk/models/application_model.rb', line 108

def is_active
  @is_active
end

#modifiedDate-time

Returns The date this application was last modified.

Returns:

  • (Date-time)

    The date this application was last modified



104
105
106
# File 'lib/lockstep_sdk/models/application_model.rb', line 104

def modified
  @modified
end

#modified_user_idUuid

Returns The ID of the user who last modified this application.

Returns:

  • (Uuid)

    The ID of the user who last modified this application



96
97
98
# File 'lib/lockstep_sdk/models/application_model.rb', line 96

def modified_user_id
  @modified_user_id
end

#nameString

Returns The name of this application.

Returns:

  • (String)

    The name of this application



64
65
66
# File 'lib/lockstep_sdk/models/application_model.rb', line 64

def name
  @name
end

#notesNoteModel

Returns All notes attached to this app. To retrieve this collection, specify `Notes` in the “Include” parameter for your query.

Returns:

  • (NoteModel)

    All notes attached to this app. To retrieve this collection, specify `Notes` in the “Include” parameter for your query.



120
121
122
# File 'lib/lockstep_sdk/models/application_model.rb', line 120

def notes
  @notes
end

#owner_idUuid

Returns The ID of the owner.

Returns:

  • (Uuid)

    The ID of the owner



76
77
78
# File 'lib/lockstep_sdk/models/application_model.rb', line 76

def owner_id
  @owner_id
end

#price_termsString

Returns The description of the price for this application.

Returns:

  • (String)

    The description of the price for this application



88
89
90
# File 'lib/lockstep_sdk/models/application_model.rb', line 88

def price_terms
  @price_terms
end

#project_urlUri

Returns The URL to visit for more information about this application.

Returns:

  • (Uri)

    The URL to visit for more information about this application



80
81
82
# File 'lib/lockstep_sdk/models/application_model.rb', line 80

def project_url
  @project_url
end

#wiki_urlUri

Returns URL to the Wiki for the Application.

Returns:

  • (Uri)

    URL to the Wiki for the Application



112
113
114
# File 'lib/lockstep_sdk/models/application_model.rb', line 112

def wiki_url
  @wiki_url
end

Instance Method Details

#as_json(options = {}) ⇒ object

Returns This object as a JSON key-value structure.

Returns:

  • (object)

    This object as a JSON key-value structure



136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
# File 'lib/lockstep_sdk/models/application_model.rb', line 136

def as_json(options={})
    {
        'appId' => @app_id,
        'name' => @name,
        'description' => @description,
        'appType' => @app_type,
        'ownerId' => @owner_id,
        'projectUrl' => @project_url,
        'iconUrl' => @icon_url,
        'priceTerms' => @price_terms,
        'createdUserId' => @created_user_id,
        'modifiedUserId' => @modified_user_id,
        'created' => @created,
        'modified' => @modified,
        'isActive' => @is_active,
        'wikiURL' => @wiki_url,
        'groupKey' => @group_key,
        'notes' => @notes,
        'attachments' => @attachments,
        'customFieldDefinitions' => @custom_field_definitions,
        'customFieldValues' => @custom_field_values,
    }
end

#to_json(*options) ⇒ String

Returns This object converted to a JSON string.

Returns:

  • (String)

    This object converted to a JSON string



162
163
164
# File 'lib/lockstep_sdk/models/application_model.rb', line 162

def to_json(*options)
    "[#{as_json(*options).to_json(*options)}]"
end