Class: Google::Apis::ClassroomV1::Course

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

A Course in Classroom.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Google::Apis::Core::JsonObjectSupport

#to_json

Methods included from Google::Apis::Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ Course

Returns a new instance of Course



251
252
253
# File 'generated/google/apis/classroom_v1/classes.rb', line 251

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

Instance Attribute Details

Absolute link to this course in the Classroom web UI. Read-only. Corresponds to the JSON property alternateLink

Returns:

  • (String)


129
130
131
# File 'generated/google/apis/classroom_v1/classes.rb', line 129

def alternate_link
  @alternate_link
end

#calendar_idString

The Calendar ID for a calendar that all course members can see, to which Classroom adds events for course work and announcements in the course. Read-only. Corresponds to the JSON property calendarId

Returns:

  • (String)


123
124
125
# File 'generated/google/apis/classroom_v1/classes.rb', line 123

def calendar_id
  @calendar_id
end

#course_group_emailString

The email address of a Google group containing all members of the course. This group does not accept email and can only be used for permissions. Read-only. Corresponds to the JSON property courseGroupEmail

Returns:

  • (String)


228
229
230
# File 'generated/google/apis/classroom_v1/classes.rb', line 228

def course_group_email
  @course_group_email
end

#course_material_setsArray<Google::Apis::ClassroomV1::CourseMaterialSet>

Sets of materials that appear on the "about" page of this course. Read-only. Corresponds to the JSON property courseMaterialSets



234
235
236
# File 'generated/google/apis/classroom_v1/classes.rb', line 234

def course_material_sets
  @course_material_sets
end

#course_stateString

State of the course. If unspecified, the default state is PROVISIONED. Corresponds to the JSON property courseState

Returns:

  • (String)


156
157
158
# File 'generated/google/apis/classroom_v1/classes.rb', line 156

def course_state
  @course_state
end

#creation_timeString

Creation time of the course. Specifying this field in a course update mask results in an error. Read-only. Corresponds to the JSON property creationTime

Returns:

  • (String)


180
181
182
# File 'generated/google/apis/classroom_v1/classes.rb', line 180

def creation_time
  @creation_time
end

#descriptionString

Optional description. For example, "We'll be learning about the structure of living creatures from a combination of textbooks, guest lectures, and lab work. Expect to be excited!" If set, this field must be a valid UTF-8 string and no longer than 30,000 characters. Corresponds to the JSON property description

Returns:

  • (String)


166
167
168
# File 'generated/google/apis/classroom_v1/classes.rb', line 166

def description
  @description
end

#description_headingString

Optional heading for the description. For example, "Welcome to 10th Grade Biology." If set, this field must be a valid UTF-8 string and no longer than 3600 characters. Corresponds to the JSON property descriptionHeading

Returns:

  • (String)


249
250
251
# File 'generated/google/apis/classroom_v1/classes.rb', line 249

def description_heading
  @description_heading
end

#enrollment_codeString

Enrollment code to use when joining this course. Specifying this field in a course update mask results in an error. Read-only. Corresponds to the JSON property enrollmentCode

Returns:

  • (String)


241
242
243
# File 'generated/google/apis/classroom_v1/classes.rb', line 241

def enrollment_code
  @enrollment_code
end

#guardians_enabledBoolean Also known as: guardians_enabled?

Whether or not guardian notifications are enabled for this course. Read-only. Corresponds to the JSON property guardiansEnabled

Returns:

  • (Boolean)


135
136
137
# File 'generated/google/apis/classroom_v1/classes.rb', line 135

def guardians_enabled
  @guardians_enabled
end

#idString

Identifier for this course assigned by Classroom. When creating a course, you may optionally set this identifier to an alias string in the request to create a corresponding alias. The id is still assigned by Classroom and cannot be updated after the course is created. Specifying this field in a course update mask results in an error. Corresponds to the JSON property id

Returns:

  • (String)


213
214
215
# File 'generated/google/apis/classroom_v1/classes.rb', line 213

def id
  @id
end

#nameString

Name of the course. For example, "10th Grade Biology". The name is required. It must be between 1 and 750 characters and a valid UTF-8 string. Corresponds to the JSON property name

Returns:

  • (String)


193
194
195
# File 'generated/google/apis/classroom_v1/classes.rb', line 193

def name
  @name
end

#owner_idString

The identifier of the owner of a course. When specified as a parameter of a create course request, this field is required. The identifier can be one of the following:

  • the numeric identifier for the user
  • the email address of the user
  • the string literal "me", indicating the requesting user This must be set in a create request. Specifying this field in a course update mask results in an INVALID_ARGUMENT error. Corresponds to the JSON property ownerId

Returns:

  • (String)


150
151
152
# File 'generated/google/apis/classroom_v1/classes.rb', line 150

def owner_id
  @owner_id
end

#roomString

Optional room location. For example, "301". If set, this field must be a valid UTF-8 string and no longer than 650 characters. Corresponds to the JSON property room

Returns:

  • (String)


221
222
223
# File 'generated/google/apis/classroom_v1/classes.rb', line 221

def room
  @room
end

#sectionString

Section of the course. For example, "Period 2". If set, this field must be a valid UTF-8 string and no longer than 2800 characters. Corresponds to the JSON property section

Returns:

  • (String)


201
202
203
# File 'generated/google/apis/classroom_v1/classes.rb', line 201

def section
  @section
end

#teacher_folderGoogle::Apis::ClassroomV1::DriveFolder

Representation of a Google Drive folder. Corresponds to the JSON property teacherFolder



185
186
187
# File 'generated/google/apis/classroom_v1/classes.rb', line 185

def teacher_folder
  @teacher_folder
end

#teacher_group_emailString

The email address of a Google group containing all teachers of the course. This group does not accept email and can only be used for permissions. Read-only. Corresponds to the JSON property teacherGroupEmail

Returns:

  • (String)


173
174
175
# File 'generated/google/apis/classroom_v1/classes.rb', line 173

def teacher_group_email
  @teacher_group_email
end

#update_timeString

Time of the most recent update to this course. Specifying this field in a course update mask results in an error. Read-only. Corresponds to the JSON property updateTime

Returns:

  • (String)


116
117
118
# File 'generated/google/apis/classroom_v1/classes.rb', line 116

def update_time
  @update_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
# File 'generated/google/apis/classroom_v1/classes.rb', line 256

def update!(**args)
  @update_time = args[:update_time] if args.key?(:update_time)
  @calendar_id = args[:calendar_id] if args.key?(:calendar_id)
  @alternate_link = args[:alternate_link] if args.key?(:alternate_link)
  @guardians_enabled = args[:guardians_enabled] if args.key?(:guardians_enabled)
  @owner_id = args[:owner_id] if args.key?(:owner_id)
  @course_state = args[:course_state] if args.key?(:course_state)
  @description = args[:description] if args.key?(:description)
  @teacher_group_email = args[:teacher_group_email] if args.key?(:teacher_group_email)
  @creation_time = args[:creation_time] if args.key?(:creation_time)
  @teacher_folder = args[:teacher_folder] if args.key?(:teacher_folder)
  @name = args[:name] if args.key?(:name)
  @section = args[:section] if args.key?(:section)
  @id = args[:id] if args.key?(:id)
  @room = args[:room] if args.key?(:room)
  @course_group_email = args[:course_group_email] if args.key?(:course_group_email)
  @course_material_sets = args[:course_material_sets] if args.key?(:course_material_sets)
  @enrollment_code = args[:enrollment_code] if args.key?(:enrollment_code)
  @description_heading = args[:description_heading] if args.key?(:description_heading)
end