Skip to content

Commit

Permalink
Merge pull request #82 from thomasvl/services_update
Browse files Browse the repository at this point in the history
Update services with today changes.
  • Loading branch information
thomasvl authored Jan 11, 2017
2 parents 6805611 + f0ba146 commit 42fd11e
Show file tree
Hide file tree
Showing 14 changed files with 601 additions and 271 deletions.
31 changes: 19 additions & 12 deletions Source/GeneratedServices/Classroom/GTLRClassroomObjects.h
Original file line number Diff line number Diff line change
Expand Up @@ -190,19 +190,20 @@ GTLR_EXTERN NSString * const kGTLRClassroom_StudentSubmission_State_TurnedIn;

/**
* Attachments added by the student. Drive files that correspond to materials
* with a share mode of SUBMISSION_COPY may not exist yet if the student has
* not accessed the assignment in Classroom. Some attachment metadata is only
* with a share mode of STUDENT_COPY may not exist yet if the student has not
* accessed the assignment in Classroom. Some attachment metadata is only
* populated if the requesting user has permission to access it. Identifier and
* alternate_link fields are available, but others (e.g. title) may not be.
* alternate_link fields are always available, but others (e.g. title) may not
* be.
*/
@property(nonatomic, strong, nullable) NSArray<GTLRClassroom_Attachment *> *attachments;

@end


/**
* Attachment added to student assignment work. When creating attachments, only
* the Link field may be specified.
* Attachment added to student assignment work. When creating attachments,
* setting the `form` field is not supported.
*/
@interface GTLRClassroom_Attachment : GTLRObject

Expand Down Expand Up @@ -428,6 +429,7 @@ GTLR_EXTERN NSString * const kGTLRClassroom_StudentSubmission_State_TurnedIn;

/**
* Assignment details. This is populated only when `work_type` is `ASSIGNMENT`.
* Read-only.
*/
@property(nonatomic, strong, nullable) GTLRClassroom_Assignment *assignment;

Expand Down Expand Up @@ -488,8 +490,10 @@ GTLR_EXTERN NSString * const kGTLRClassroom_StudentSubmission_State_TurnedIn;
@property(nonatomic, strong, nullable) NSNumber *maxPoints;

/**
* Multiple choice question details. This is populated only when `work_type` is
* `MULTIPLE_CHOICE_QUESTION`.
* Multiple choice question details. For read operations, this field is
* populated only when `work_type` is `MULTIPLE_CHOICE_QUESTION`. For write
* operations, this field must be specified when creating course work with a
* `work_type` of `MULTIPLE_CHOICE_QUESTION`, and it must not be set otherwise.
*/
@property(nonatomic, strong, nullable) GTLRClassroom_MultipleChoiceQuestion *multipleChoiceQuestion;

Expand Down Expand Up @@ -530,7 +534,7 @@ GTLR_EXTERN NSString * const kGTLRClassroom_StudentSubmission_State_TurnedIn;

/**
* Type of this course work. The type is set when the course work is created
* and cannot be changed. When creating course work, this must be `ASSIGNMENT`.
* and cannot be changed.
*
* Likely values:
* @arg @c kGTLRClassroom_CourseWork_WorkType_Assignment Value "ASSIGNMENT"
Expand Down Expand Up @@ -1043,8 +1047,8 @@ GTLR_EXTERN NSString * const kGTLRClassroom_StudentSubmission_State_TurnedIn;


/**
* Material attached to course work. When creating attachments, only the Link
* field may be specified.
* Material attached to course work. When creating attachments, setting the
* `form` field is not supported.
*/
@interface GTLRClassroom_Material : GTLRObject

Expand All @@ -1054,7 +1058,10 @@ GTLR_EXTERN NSString * const kGTLRClassroom_StudentSubmission_State_TurnedIn;
/** Google Forms material. */
@property(nonatomic, strong, nullable) GTLRClassroom_Form *form;

/** Link material. */
/**
* Link material. On creation, will be upgraded to a more appropriate type if
* possible, and this will be reflected in the response.
*/
@property(nonatomic, strong, nullable) GTLRClassroom_Link *link;

/** YouTube video material. */
Expand All @@ -1070,7 +1077,7 @@ GTLR_EXTERN NSString * const kGTLRClassroom_StudentSubmission_State_TurnedIn;

/**
* Attachments to add. A student submission may not have more than 20
* attachments. This may only contain link attachments.
* attachments. Form attachments are not supported.
*/
@property(nonatomic, strong, nullable) NSArray<GTLRClassroom_Attachment *> *addAttachments;

Expand Down
255 changes: 203 additions & 52 deletions Source/GeneratedServices/Classroom/GTLRClassroomQuery.h

Large diffs are not rendered by default.

60 changes: 60 additions & 0 deletions Source/GeneratedServices/Classroom/GTLRClassroomQuery.m
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,33 @@ + (instancetype)queryWithObject:(GTLRClassroom_CourseWork *)object

@end

@implementation GTLRClassroomQuery_CoursesCourseWorkDelete

@dynamic courseId, identifier;

+ (NSDictionary<NSString *, NSString *> *)parameterNameMap {
return @{ @"identifier" : @"id" };
}

+ (instancetype)queryWithCourseId:(NSString *)courseId
identifier:(NSString *)identifier {
NSArray *pathParams = @[
@"courseId", @"id"
];
NSString *pathURITemplate = @"v1/courses/{courseId}/courseWork/{id}";
GTLRClassroomQuery_CoursesCourseWorkDelete *query =
[[self alloc] initWithPathURITemplate:pathURITemplate
HTTPMethod:@"DELETE"
pathParameterNames:pathParams];
query.courseId = courseId;
query.identifier = identifier;
query.expectedObjectClass = [GTLRClassroom_Empty class];
query.loggingName = @"classroom.courses.courseWork.delete";
return query;
}

@end

@implementation GTLRClassroomQuery_CoursesCourseWorkGet

@dynamic courseId, identifier;
Expand Down Expand Up @@ -199,6 +226,39 @@ + (instancetype)queryWithCourseId:(NSString *)courseId {

@end

@implementation GTLRClassroomQuery_CoursesCourseWorkPatch

@dynamic courseId, identifier, updateMask;

+ (NSDictionary<NSString *, NSString *> *)parameterNameMap {
return @{ @"identifier" : @"id" };
}

+ (instancetype)queryWithObject:(GTLRClassroom_CourseWork *)object
courseId:(NSString *)courseId
identifier:(NSString *)identifier {
if (object == nil) {
GTLR_DEBUG_ASSERT(object != nil, @"Got a nil object");
return nil;
}
NSArray *pathParams = @[
@"courseId", @"id"
];
NSString *pathURITemplate = @"v1/courses/{courseId}/courseWork/{id}";
GTLRClassroomQuery_CoursesCourseWorkPatch *query =
[[self alloc] initWithPathURITemplate:pathURITemplate
HTTPMethod:@"PATCH"
pathParameterNames:pathParams];
query.bodyObject = object;
query.courseId = courseId;
query.identifier = identifier;
query.expectedObjectClass = [GTLRClassroom_CourseWork class];
query.loggingName = @"classroom.courses.courseWork.patch";
return query;
}

@end

@implementation GTLRClassroomQuery_CoursesCourseWorkStudentSubmissionsGet

@dynamic courseId, courseWorkId, identifier;
Expand Down
3 changes: 1 addition & 2 deletions Source/GeneratedServices/Dataflow/GTLRDataflow.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@
// API:
// Google Dataflow API (dataflow/v1b3)
// Description:
// Develops and executes data processing patterns like ETL, batch computation,
// and continuous computation.
// Manages Google Cloud Dataflow projects on Google Cloud Platform.
// Documentation:
// https://cloud.google.com/dataflow

Expand Down
Loading

0 comments on commit 42fd11e

Please sign in to comment.