Skip to content

Instantly share code, notes, and snippets.

@hitherejoe
Last active June 30, 2016 13:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hitherejoe/bc6687cbbeca8e08e7d12a6628446374 to your computer and use it in GitHub Desktop.
Save hitherejoe/bc6687cbbeca8e08e7d12a6628446374 to your computer and use it in GitHub Desktop.
Barcode barcode = new Barcode().setType("upcA").setValue("123456789012")
.setAlternateText("12345");
OfferObject object = new OfferObject()
.setClassId('2945482443380251551.ExampleOfferClass1')
.setId('2945482443380251551.ExampleOfferObject1')
.setVersion(1L)
.setBarcode(barcode)
.setValidTimeInterval(new TimeInterval().setEnd(new DateTime().setDate(new com.google.api.client.util.DateTime(
new Date().getTime() + 263000000000L))))
.setState("active");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment