Skip to content

Commit

Permalink
Merge pull request #310 from microsoftgraph/dev
Browse files Browse the repository at this point in the history
updates from dev
  • Loading branch information
baywet authored Oct 7, 2020
2 parents 981d48c + 62ac71d commit 20b0705
Show file tree
Hide file tree
Showing 39 changed files with 117 additions and 115 deletions.
20 changes: 11 additions & 9 deletions src/GraphODataTemplateWriter/CodeHelpers/Java/TypeHelperJava.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1269,9 +1269,9 @@ public static string CreateParameterDef(IEnumerable<OdcmParameter> parameters)
* The {0}.
* {1}
*/
@SerializedName(""{2}"")
@SerializedName(value = ""{2}"", alternate = {{""{3}""}})
@Expose
public {3} {4};
public {4} {5};
";
foreach (var p in parameters)
Expand All @@ -1281,6 +1281,7 @@ public static string CreateParameterDef(IEnumerable<OdcmParameter> parameters)
p.ParamName().SplitCamelCase(),
ReplaceInvalidCharacters(p.LongDescription),
p.ParamName(),
p.ParamName().ToUpperFirstChar(),
p.ParamType(),
p.ParamName().SanitizePropertyName(p).ToLowerFirstChar()
);
Expand Down Expand Up @@ -1413,19 +1414,19 @@ public static string CreatePropertyDef(IEnumerable<OdcmProperty> properties, boo
var format =
@" /**
* The {0}.
* {4}
* {1}
*/
@SerializedName(""{1}"")
@SerializedName(value = ""{2}"", alternate = {{""{3}""}})
@Expose
public {2} {3};
public {4} {5};
";
var collectionFormat =
@" /**
* The {0}.
* {4}
* {1}
*/
public {2} {3};
public {4} {5};
";

Expand Down Expand Up @@ -1454,10 +1455,11 @@ public static string CreatePropertyDef(IEnumerable<OdcmProperty> properties, boo

sb.AppendFormat(propertyFormat,
propertyName.SplitCamelCase(),
GetSanitizedDescription(property),
property.Name,
propertyName,
propertyType,
property.Name.ToLowerFirstChar().SanitizePropertyName(property),
GetSanitizedDescription(property));
property.Name.ToLowerFirstChar().SanitizePropertyName(property));
}
return sb.ToString();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public class Call extends Entity implements IJsonBackedObject {
* The Subject.
*
*/
@SerializedName("subject")
@SerializedName(value = "subject", alternate = {"Subject"})
@Expose
public String subject;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,15 @@ public class CloudCommunications extends Entity implements IJsonBackedObject {
* The Calls.
*
*/
@SerializedName("calls")
@SerializedName(value = "calls", alternate = {"Calls"})
@Expose
public CallCollectionPage calls;

/**
* The Call Records.
*
*/
@SerializedName("callRecords")
@SerializedName(value = "callRecords", alternate = {"CallRecords"})
@Expose
public CallRecordCollectionPage callRecords;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,23 +27,23 @@ public class DerivedComplexTypeRequest extends EmptyBaseComplexTypeRequest imple
* The Property1.
*
*/
@SerializedName("property1")
@SerializedName(value = "property1", alternate = {"Property1"})
@Expose
public String property1;

/**
* The Property2.
*
*/
@SerializedName("property2")
@SerializedName(value = "property2", alternate = {"Property2"})
@Expose
public String property2;

/**
* The Enum Property.
*
*/
@SerializedName("enumProperty")
@SerializedName(value = "enumProperty", alternate = {"EnumProperty"})
@Expose
public Enum1 enumProperty;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public class DirectoryObject extends Entity implements IJsonBackedObject {
* The Deleted Date Time.
*
*/
@SerializedName("deletedDateTime")
@SerializedName(value = "deletedDateTime", alternate = {"DeletedDateTime"})
@Expose
public java.util.Calendar deletedDateTime;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public class Endpoint extends Entity implements IJsonBackedObject {
* The Property1.
*
*/
@SerializedName("property1")
@SerializedName(value = "property1", alternate = {"Property1"})
@Expose
public Long property1;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public final AdditionalDataManager additionalDataManager() {
* The Id.
*
*/
@SerializedName("id")
@SerializedName(value = "id", alternate = {"Id"})
@Expose
public String id;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,39 +23,39 @@ public class EntityType3ForwardBody {
* The to Recipients.
*
*/
@SerializedName("toRecipients")
@SerializedName(value = "toRecipients", alternate = {"ToRecipients"})
@Expose
public java.util.List<Recipient> toRecipients;

/**
* The single Recipient.
*
*/
@SerializedName("singleRecipient")
@SerializedName(value = "singleRecipient", alternate = {"SingleRecipient"})
@Expose
public Recipient singleRecipient;

/**
* The multiple Sessions.
*
*/
@SerializedName("multipleSessions")
@SerializedName(value = "multipleSessions", alternate = {"MultipleSessions"})
@Expose
public java.util.List<Session> multipleSessions;

/**
* The single Session.
*
*/
@SerializedName("singleSession")
@SerializedName(value = "singleSession", alternate = {"SingleSession"})
@Expose
public Session singleSession;

/**
* The comment.
*
*/
@SerializedName("comment")
@SerializedName(value = "comment", alternate = {"Comment"})
@Expose
public String comment;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,15 @@ public final AdditionalDataManager additionalDataManager() {
* The Display Name.
*
*/
@SerializedName("displayName")
@SerializedName(value = "displayName", alternate = {"DisplayName"})
@Expose
public String displayName;

/**
* The Id.
*
*/
@SerializedName("id")
@SerializedName(value = "id", alternate = {"Id"})
@Expose
public String id;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,23 +36,23 @@ public final AdditionalDataManager additionalDataManager() {
* The Application.
*
*/
@SerializedName("application")
@SerializedName(value = "application", alternate = {"Application"})
@Expose
public Identity application;

/**
* The Device.
*
*/
@SerializedName("device")
@SerializedName(value = "device", alternate = {"Device"})
@Expose
public Identity device;

/**
* The User.
*
*/
@SerializedName("user")
@SerializedName(value = "user", alternate = {"User"})
@Expose
public Identity user;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,23 +22,23 @@ public class OnenotePageForwardBody {
* The to Recipients.
*
*/
@SerializedName("toRecipients")
@SerializedName(value = "toRecipients", alternate = {"ToRecipients"})
@Expose
public java.util.List<Recipient> toRecipients;

/**
* The details.
*
*/
@SerializedName("details")
@SerializedName(value = "details", alternate = {"Details"})
@Expose
public String details;

/**
* The comment.
*
*/
@SerializedName("comment")
@SerializedName(value = "comment", alternate = {"Comment"})
@Expose
public String comment;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,15 @@ public final AdditionalDataManager additionalDataManager() {
* The Name.
*
*/
@SerializedName("name")
@SerializedName(value = "name", alternate = {"Name"})
@Expose
public String name;

/**
* The Email.
*
*/
@SerializedName("email")
@SerializedName(value = "email", alternate = {"Email"})
@Expose
public String email;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,23 +30,23 @@ public class Schedule extends Entity implements IJsonBackedObject {
* The Enabled.
*
*/
@SerializedName("enabled")
@SerializedName(value = "enabled", alternate = {"Enabled"})
@Expose
public Boolean enabled;

/**
* The Times Off.
*
*/
@SerializedName("timesOff")
@SerializedName(value = "timesOff", alternate = {"TimesOff"})
@Expose
public TimeOffCollectionPage timesOff;

/**
* The Time Off Requests.
*
*/
@SerializedName("timeOffRequests")
@SerializedName(value = "timeOffRequests", alternate = {"TimeOffRequests"})
@Expose
public TimeOffRequestCollectionPage timeOffRequests;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public class SingletonEntity1 extends Entity implements IJsonBackedObject {
* The Test Single Nav.
*
*/
@SerializedName("testSingleNav")
@SerializedName(value = "testSingleNav", alternate = {"TestSingleNav"})
@Expose
public TestType testSingleNav;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public class SingletonEntity2 extends Entity implements IJsonBackedObject {
* The Test Single Nav2.
*
*/
@SerializedName("testSingleNav2")
@SerializedName(value = "testSingleNav2", alternate = {"TestSingleNav2"})
@Expose
public EntityType3 testSingleNav2;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,23 +29,23 @@ public class TestEntity extends Entity implements IJsonBackedObject {
* The Test Nav.
*
*/
@SerializedName("testNav")
@SerializedName(value = "testNav", alternate = {"TestNav"})
@Expose
public TestType testNav;

/**
* The Test Invalid Nav.
*
*/
@SerializedName("testInvalidNav")
@SerializedName(value = "testInvalidNav", alternate = {"TestInvalidNav"})
@Expose
public EntityType2 testInvalidNav;

/**
* The Test Explicit Nav.
*
*/
@SerializedName("testExplicitNav")
@SerializedName(value = "testExplicitNav", alternate = {"TestExplicitNav"})
@Expose
public EntityType3 testExplicitNav;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public class TestType extends Entity implements IJsonBackedObject {
* The Property Alpha.
*
*/
@SerializedName("propertyAlpha")
@SerializedName(value = "propertyAlpha", alternate = {"PropertyAlpha"})
@Expose
public DerivedComplexTypeRequest propertyAlpha;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public class TestTypeQueryBody {
* The requests.
*
*/
@SerializedName("requests")
@SerializedName(value = "requests", alternate = {"Requests"})
@Expose
public java.util.List<DerivedComplexTypeRequest> requests;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public class TimeOff extends Entity implements IJsonBackedObject {
* The Name.
*
*/
@SerializedName("name")
@SerializedName(value = "name", alternate = {"Name"})
@Expose
public String name;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public class TimeOffRequest extends Entity implements IJsonBackedObject {
* The Name.
*
*/
@SerializedName("name")
@SerializedName(value = "name", alternate = {"Name"})
@Expose
public String name;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public class User extends DirectoryObject implements IJsonBackedObject {
* The Account Enabled.
* true if the account is enabled; otherwise, false. This property is required when a user is created. Supports $filter.
*/
@SerializedName("accountEnabled")
@SerializedName(value = "accountEnabled", alternate = {"AccountEnabled"})
@Expose
public Boolean accountEnabled;

Expand Down
Loading

0 comments on commit 20b0705

Please sign in to comment.