This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| d1 = new Date('2017-09-26') | |
| d2 = new Date('2017-09-27') | |
| d3 = new Date('2017-09-28') | |
| d4 = new Date('2017-09-30') | |
| d5 = new Date('2017-10-01') | |
| d6 = new Date('2017-10-02') | |
| d7 = new Date('2017-10-04') | |
| d8 = new Date('2017-10-05') | |
| d9 = new Date('2017-10-07') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### Keybase proof | |
| I hereby claim: | |
| * I am dailymartin on github. | |
| * I am freeism (https://keybase.io/freeism) on keybase. | |
| * I have a public key ASB9YF-MEjJwlwtbPZc3JuhCSk980HkDtJt9zyL3EFkLTAo | |
| To claim this, I am signing this object: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| private static final ObjectMapper OBJECT_MAPPER = new ObjectMapper(); | |
| ... | |
| private byte[] createPKPassBinaries(PKPass pass, PKSigningInformation pkSigningInformation, InputStream thumbnail, InputStream thumbnail2x) throws Exception { | |
| return new PKFileBasedSigningUtil(OBJECT_MAPPER).createSignedAndZippedPkPassArchive(pass, createPKPassTemplate(thumbnail, thumbnail2x), pkSigningInformation); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| protected ObjectWriter configureObjectMapper(ObjectMapper jsonObjectMapper) { | |
| jsonObjectMapper.configure(SerializationFeature.WRITE_DATES_AS_TIMESTAMPS, false); | |
| jsonObjectMapper.setDateFormat(new ISO8601DateFormat()); | |
| SimpleFilterProvider filters = new SimpleFilterProvider(); | |
| filters.addFilter("validateFilter", SimpleBeanPropertyFilter.serializeAllExcept(new String[]{"valid", "validationErrors"})); | |
| filters.addFilter("pkPassFilter", SimpleBeanPropertyFilter.serializeAllExcept(new String[]{"valid", "validationErrors", "foregroundColorAsObject", "backgroundColorAsObject", "labelColorAsObject", "passThatWasSet"})); | |
| filters.addFilter("barcodeFilter", SimpleBeanPropertyFilter.serializeAllExcept(new String[]{"valid", "validationErrors", "messageEncodingAsString"})); | |
| filters.addFilter("charsetFilter", SimpleBeanPropertyFilter.filterOutAllExcept(new String[]{"name"})); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public final class PKFileBasedSigningUtil extends PKAbstractSIgningUtil { | |
| private static final String FILE_SEPARATOR_UNIX = "/"; | |
| private static final String MANIFEST_JSON_FILE_NAME = "manifest.json"; | |
| private static final String PASS_JSON_FILE_NAME = "pass.json"; | |
| private ObjectWriter objectWriter; | |
| @Inject | |
| public PKFileBasedSigningUtil(ObjectMapper objectMapper) { | |
| this.addBCProvider(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @Primary | |
| @Bean | |
| public ObjectMapper objectMapper() { | |
| ObjectMapper objectMapper = new CustomObjectMapper(); | |
| initializeObjectMapper(objectMapper); | |
| return objectMapper; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!-- PassKit --> | |
| <dependency> | |
| <groupId>de.brendamour</groupId> | |
| <artifactId>jpasskit</artifactId> | |
| <version>0.0.8</version> | |
| <exclusions> | |
| <exclusion> | |
| <groupId>com.fasterxml.jackson.core</groupId> | |
| <artifactId>jackson-core</artifactId> | |
| </exclusion> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| com.fasterxml.jackson.databind.JsonMappingException: Can not resolve PropertyFilter with id 'validateFilter'; no FilterProvider configured |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!-- PassKit --> | |
| <dependency> | |
| <groupId>de.brendamour</groupId> | |
| <artifactId>jpasskit</artifactId> | |
| <version>0.0.8</version> | |
| </dependency> |