# ClassGroup

Represents a class group on SMHW.

## Constructor

#### new ClassGroup(client, response)

Instantiate a ClassGroup object.

Parameters:

Name | Type | Description
--- | --- | ---
`client` | Client | The client that is instantiating the object.
`response` | Object | The data for the object.

Source:
  - structures/ClassGroup.js, line 10

### Members

#### (private) _client :Client

The client that instantiated this object.

Type:

- Client

Source:
  - structures/ClassGroup.js, line 16

#### academic_year_id :Number

The ID of the academic year that the class group is in.

Type:

- Number

Source:
  - structures/ClassGroup.js, line 22

#### class_year :String

The class year that the class group is in.

Type:

- String

Source:
  - structures/ClassGroup.js, line 28

#### id :Number

The ID of the class group

Type:

- Number

Source:
  - structures/ClassGroup.js, line 34

#### imported_via_sims :Boolean

Whether or not the class group has been imported via sims.

Type:

- Boolean

Source:
  - structures/ClassGroup.js, line 40

#### is_registration_group :Boolean

Whether or not the class group is a registration group.

Type:

- Boolean

Source:
  - structures/ClassGroup.js, line 46

#### left_at :Number

The timestamp of when the class group left. (?)

Type:

- Number

Source:
  - structures/ClassGroup.js, line 53

#### links :Object

Links for API resources for the class group.

Type:

- Object

Source:
  - structures/ClassGroup.js, line 59

#### name :String

The name of the class group.

Type:

- String

Source:
  - structures/ClassGroup.js, line 71

#### school_id :Number

The ID of the school that the class group belongs to.

Type:

- Number

Source:
  - structures/ClassGroup.js, line 77

#### student_ids :Array.<Number>

An array of IDs for students in the class group.

Type:

- Array.<Number>

Source:
  - structures/ClassGroup.js, line 83

#### teacher_ids :Array.<Number>

An array of IDs for teachers in the class group.

Type:

- Array.<Number>

Source:
  - structures/ClassGroup.js, line 89

### Methods

#### getSchool() → {Promise.<School>}

Get the school that the class group belongs to.

Source:
  - structures/ClassGroup.js, line 96

Returns:

Type
  Promise.<School>

#### getStudents(idsopt) → {Promise.<Array.<Student>>}

Get students in the class group.

Parameters:

Name | Type | Attributes | Description
--- | --- | --- | ---
`ids` | Array.<Number> | <optional> | An array of student IDs to retrieve.

Source:
  - structures/ClassGroup.js, line 105

Returns:

Type
  Promise.<Array.<Student>>

#### getTeachers(idsopt) → {Promise.<Array.<Employee>>}

Get teachers in the class group.

Parameters:

Name | Type | Attributes | Description
--- | --- | --- | ---
`ids` | Array.<Number> | <optional> | An array of teacher IDs to retrieve.

Source:
  - structures/ClassGroup.js, line 114

Returns:

Type
  Promise.<Array.<Employee>>