Class: MicrosoftGraph::Models::DirectoryAudit

Inherits:
Entity
  • Object
show all
Includes:
MicrosoftKiotaAbstractions::Parsable
Defined in:
lib/models/directory_audit.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Entity

#additional_data, #additional_data=, #id, #id=, #odata_type, #odata_type=

Constructor Details

#initializeObject

Instantiates a new directoryAudit and sets the default values.



107
108
109
# File 'lib/models/directory_audit.rb', line 107

def initialize()
    super
end

Class Method Details

.create_from_discriminator_value(parse_node) ⇒ Object

Creates a new instance of the appropriate class based on discriminator value

Parameters:

  • parse_node

    The parse node to use to read the discriminator value and create the object

Returns:

  • a directory_audit

Raises:

  • (StandardError)


130
131
132
133
# File 'lib/models/directory_audit.rb', line 130

def self.create_from_discriminator_value(parse_node)
    raise StandardError, 'parse_node cannot be null' if parse_node.nil?
    return DirectoryAudit.new
end

Instance Method Details

#activity_date_timeObject

Gets the activityDateTime property value. Indicates the date and time the activity was performed. The Timestamp type is always in UTC time. For example, midnight UTC on Jan 1, 2014 is 2014-01-01T00:00:00Z. Supports $filter (eq, ge, le) and $orderby.

Returns:

  • a date_time



47
48
49
# File 'lib/models/directory_audit.rb', line 47

def activity_date_time
    return @activity_date_time
end

#activity_date_time=(value) ⇒ Object

Sets the activityDateTime property value. Indicates the date and time the activity was performed. The Timestamp type is always in UTC time. For example, midnight UTC on Jan 1, 2014 is 2014-01-01T00:00:00Z. Supports $filter (eq, ge, le) and $orderby.

Parameters:

  • value

    Value to set for the activityDateTime property.

Returns:

  • a void



55
56
57
# File 'lib/models/directory_audit.rb', line 55

def activity_date_time=(value)
    @activity_date_time = value
end

#activity_display_nameObject

Gets the activityDisplayName property value. Indicates the activity name or the operation name (examples: ‘Create User’ and ‘Add member to group’). For a list of activities logged, refer to Azure AD audit log categories and activities. Supports $filter (eq, startswith).

Returns:

  • a string



62
63
64
# File 'lib/models/directory_audit.rb', line 62

def activity_display_name
    return @activity_display_name
end

#activity_display_name=(value) ⇒ Object

Sets the activityDisplayName property value. Indicates the activity name or the operation name (examples: ‘Create User’ and ‘Add member to group’). For a list of activities logged, refer to Azure AD audit log categories and activities. Supports $filter (eq, startswith).

Parameters:

  • value

    Value to set for the activityDisplayName property.

Returns:

  • a void



70
71
72
# File 'lib/models/directory_audit.rb', line 70

def activity_display_name=(value)
    @activity_display_name = value
end

#additional_detailsObject

Gets the additionalDetails property value. Indicates additional details on the activity.

Returns:

  • a key_value



77
78
79
# File 'lib/models/directory_audit.rb', line 77

def additional_details
    return @additional_details
end

#additional_details=(value) ⇒ Object

Sets the additionalDetails property value. Indicates additional details on the activity.

Parameters:

  • value

    Value to set for the additionalDetails property.

Returns:

  • a void



85
86
87
# File 'lib/models/directory_audit.rb', line 85

def additional_details=(value)
    @additional_details = value
end

#categoryObject

Gets the category property value. Indicates which resource category that’s targeted by the activity. For example: UserManagement, GroupManagement, ApplicationManagement, RoleManagement. For a list of categories for activities logged, refer to Azure AD audit log categories and activities.

Returns:

  • a string



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

def category
    return @category
end

#category=(value) ⇒ Object

Sets the category property value. Indicates which resource category that’s targeted by the activity. For example: UserManagement, GroupManagement, ApplicationManagement, RoleManagement. For a list of categories for activities logged, refer to Azure AD audit log categories and activities.

Parameters:

  • value

    Value to set for the category property.

Returns:

  • a void



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

def category=(value)
    @category = value
end

#correlation_idObject

Gets the correlationId property value. Indicates a unique ID that helps correlate activities that span across various services. Can be used to trace logs across services. Supports $filter (eq).

Returns:

  • a string



114
115
116
# File 'lib/models/directory_audit.rb', line 114

def correlation_id
    return @correlation_id
end

#correlation_id=(value) ⇒ Object

Sets the correlationId property value. Indicates a unique ID that helps correlate activities that span across various services. Can be used to trace logs across services. Supports $filter (eq).

Parameters:

  • value

    Value to set for the correlationId property.

Returns:

  • a void



122
123
124
# File 'lib/models/directory_audit.rb', line 122

def correlation_id=(value)
    @correlation_id = value
end

#get_field_deserializersObject

The deserialization information for the current model

Returns:

  • a i_dictionary



138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
# File 'lib/models/directory_audit.rb', line 138

def get_field_deserializers()
    return super.merge({
        "activityDateTime" => lambda {|n| @activity_date_time = n.get_date_time_value() },
        "activityDisplayName" => lambda {|n| @activity_display_name = n.get_string_value() },
        "additionalDetails" => lambda {|n| @additional_details = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::KeyValue.create_from_discriminator_value(pn) }) },
        "category" => lambda {|n| @category = n.get_string_value() },
        "correlationId" => lambda {|n| @correlation_id = n.get_string_value() },
        "initiatedBy" => lambda {|n| @initiated_by = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::AuditActivityInitiator.create_from_discriminator_value(pn) }) },
        "loggedByService" => lambda {|n| @logged_by_service = n.get_string_value() },
        "operationType" => lambda {|n| @operation_type = n.get_string_value() },
        "result" => lambda {|n| @result = n.get_enum_value(MicrosoftGraph::Models::OperationResult) },
        "resultReason" => lambda {|n| @result_reason = n.get_string_value() },
        "targetResources" => lambda {|n| @target_resources = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::TargetResource.create_from_discriminator_value(pn) }) },
    })
end

#initiated_byObject

Gets the initiatedBy property value. The initiatedBy property

Returns:

  • a audit_activity_initiator



157
158
159
# File 'lib/models/directory_audit.rb', line 157

def initiated_by
    return @initiated_by
end

#initiated_by=(value) ⇒ Object

Sets the initiatedBy property value. The initiatedBy property

Parameters:

  • value

    Value to set for the initiatedBy property.

Returns:

  • a void



165
166
167
# File 'lib/models/directory_audit.rb', line 165

def initiated_by=(value)
    @initiated_by = value
end

#logged_by_serviceObject

Gets the loggedByService property value. Indicates information on which service initiated the activity (For example: Self-service Password Management, Core Directory, B2C, Invited Users, Microsoft Identity Manager, Privileged Identity Management. Supports $filter (eq).

Returns:

  • a string



172
173
174
# File 'lib/models/directory_audit.rb', line 172

def logged_by_service
    return @logged_by_service
end

#logged_by_service=(value) ⇒ Object

Sets the loggedByService property value. Indicates information on which service initiated the activity (For example: Self-service Password Management, Core Directory, B2C, Invited Users, Microsoft Identity Manager, Privileged Identity Management. Supports $filter (eq).

Parameters:

  • value

    Value to set for the loggedByService property.

Returns:

  • a void



180
181
182
# File 'lib/models/directory_audit.rb', line 180

def logged_by_service=(value)
    @logged_by_service = value
end

#operation_typeObject

Gets the operationType property value. Indicates the type of operation that was performed. The possible values include but are not limited to the following: Add, Assign, Update, Unassign, and Delete.

Returns:

  • a string



187
188
189
# File 'lib/models/directory_audit.rb', line 187

def operation_type
    return @operation_type
end

#operation_type=(value) ⇒ Object

Sets the operationType property value. Indicates the type of operation that was performed. The possible values include but are not limited to the following: Add, Assign, Update, Unassign, and Delete.

Parameters:

  • value

    Value to set for the operationType property.

Returns:

  • a void



195
196
197
# File 'lib/models/directory_audit.rb', line 195

def operation_type=(value)
    @operation_type = value
end

#resultObject

Gets the result property value. Indicates the result of the activity. Possible values are: success, failure, timeout, unknownFutureValue.

Returns:

  • a operation_result



202
203
204
# File 'lib/models/directory_audit.rb', line 202

def result
    return @result
end

#result=(value) ⇒ Object

Sets the result property value. Indicates the result of the activity. Possible values are: success, failure, timeout, unknownFutureValue.

Parameters:

  • value

    Value to set for the result property.

Returns:

  • a void



210
211
212
# File 'lib/models/directory_audit.rb', line 210

def result=(value)
    @result = value
end

#result_reasonObject

Gets the resultReason property value. Indicates the reason for failure if the result is failure or timeout.

Returns:

  • a string



217
218
219
# File 'lib/models/directory_audit.rb', line 217

def result_reason
    return @result_reason
end

#result_reason=(value) ⇒ Object

Sets the resultReason property value. Indicates the reason for failure if the result is failure or timeout.

Parameters:

  • value

    Value to set for the resultReason property.

Returns:

  • a void



225
226
227
# File 'lib/models/directory_audit.rb', line 225

def result_reason=(value)
    @result_reason = value
end

#serialize(writer) ⇒ Object

Serializes information the current object

Parameters:

  • writer

    Serialization writer to use to serialize this model

Returns:

  • a void

Raises:

  • (StandardError)


233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
# File 'lib/models/directory_audit.rb', line 233

def serialize(writer)
    raise StandardError, 'writer cannot be null' if writer.nil?
    super
    writer.write_date_time_value("activityDateTime", @activity_date_time)
    writer.write_string_value("activityDisplayName", @activity_display_name)
    writer.write_collection_of_object_values("additionalDetails", @additional_details)
    writer.write_string_value("category", @category)
    writer.write_string_value("correlationId", @correlation_id)
    writer.write_object_value("initiatedBy", @initiated_by)
    writer.write_string_value("loggedByService", @logged_by_service)
    writer.write_string_value("operationType", @operation_type)
    writer.write_enum_value("result", @result)
    writer.write_string_value("resultReason", @result_reason)
    writer.write_collection_of_object_values("targetResources", @target_resources)
end

#target_resourcesObject

Gets the targetResources property value. Indicates information on which resource was changed due to the activity. Target Resource Type can be User, Device, Directory, App, Role, Group, Policy or Other. Supports $filter (eq) for id and displayName; and $filter (startswith) for displayName.

Returns:

  • a target_resource



252
253
254
# File 'lib/models/directory_audit.rb', line 252

def target_resources
    return @target_resources
end

#target_resources=(value) ⇒ Object

Sets the targetResources property value. Indicates information on which resource was changed due to the activity. Target Resource Type can be User, Device, Directory, App, Role, Group, Policy or Other. Supports $filter (eq) for id and displayName; and $filter (startswith) for displayName.

Parameters:

  • value

    Value to set for the targetResources property.

Returns:

  • a void



260
261
262
# File 'lib/models/directory_audit.rb', line 260

def target_resources=(value)
    @target_resources = value
end