Class: Google::Apis::ClassroomV1::CourseAlias

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
generated/google/apis/classroom_v1/classes.rb,
generated/google/apis/classroom_v1/representations.rb,
generated/google/apis/classroom_v1/representations.rb

Overview

Alternative identifier for a course. An alias uniquely identifies a course. It must be unique within one of the following scopes: * domain: A domain-scoped alias is visible to all users within the alias creator's domain and can be created only by a domain admin. A domain-scoped alias is often used when a course has an identifier external to Classroom. * project: A project-scoped alias is visible to any request from an application using the Developer Console project ID that created the alias and can be created by any project. A project-scoped alias is often used when an application has alternative identifiers. A random value can also be used to avoid duplicate courses in the event of transmission failures, as retrying a request will return ALREADY_EXISTS if a previous one has succeeded.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ CourseAlias

Returns a new instance of CourseAlias.



387
388
389
# File 'generated/google/apis/classroom_v1/classes.rb', line 387

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#aliasString

Alias string. The format of the string indicates the desired alias scoping. * d: indicates a domain-scoped alias. Example: d:math_101 * p: indicates a project-scoped alias. Example: p:abc123 This field has a maximum length of 256 characters. Corresponds to the JSON property alias

Returns:

  • (String)


385
386
387
# File 'generated/google/apis/classroom_v1/classes.rb', line 385

def alias
  @alias
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



392
393
394
# File 'generated/google/apis/classroom_v1/classes.rb', line 392

def update!(**args)
  @alias = args[:alias] if args.key?(:alias)
end