Skip to content
This repository was archived by the owner on Sep 4, 2020. It is now read-only.

Fix processing of RecurrenceRange#13

Merged
peternied merged 18 commits intomicrosoftgraph:masterfrom
iambmelt:recurrence
Apr 27, 2016
Merged

Fix processing of RecurrenceRange#13
peternied merged 18 commits intomicrosoftgraph:masterfrom
iambmelt:recurrence

Conversation

@iambmelt
Copy link
Copy Markdown
Contributor

@peternied note this change also ups gradle to 2.0.0, and the gradlewrapper from 2.8-all to 2.10-all

This PR includes changes to auto-generated file BaseRecurrenceRange.java

@msftclas
Copy link
Copy Markdown

Hi @iambmelt, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution!


It looks like you're a Microsoft contributor (Brian Melton). If you're full-time, we DON'T require a Contribution License Agreement. If you are a vendor, please DO sign the electronic Contribution License Agreement. It will take 2 minutes and there's no faxing! https://cla.microsoft.com.

TTYL, MSBOT;


import com.microsoft.graph.model.Date;

public class DateSerializerTest extends AndroidTestCase {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you create a ReocurranceRange and make sure it can be serialized and deserialized with the expected output?


// validate our split datestring
if (dateInfo.length != 3) {
throw new ParseException("Datestring input didn't match format 'yyyy-mm-dd'", 0);
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does the index used here for the ParseException matter? I'm not clear on what value makes sense to use

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Its mean to a helpful hint to developers, instead of trying to figure out the index, include the dateStr in the message so it is easy to side by side it.

*
* @param dateStr date string of the form <code>yyyy-mm-dd</code>
*/
public DateOnly(String dateStr) throws ParseException {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry I missed this before, Make this a static function, public DateOnly Parse(String ...) throws ParseException {..}, that returns a DateOnly instance. We shouldn't be parsing and throwing exceptions in a ctor

@@ -25,13 +18,13 @@
*/
public class BaseRecurrenceRange implements IJsonBackedObject {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file has a number of changes that do not look like they are from the code generation library, could you update this file with that output?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can do see ae6f96f

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants