You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@daffodil.apache.org by GitBox <gi...@apache.org> on 2018/07/27 16:27:31 UTC
[GitHub] mbeckerle commented on a change in pull request #86: Adding value
of 'bcd' to binaryCalendarRep
mbeckerle commented on a change in pull request #86: Adding value of 'bcd' to binaryCalendarRep
URL: https://github.com/apache/incubator-daffodil/pull/86#discussion_r205828830
##########
File path: daffodil-core/src/main/scala/org/apache/daffodil/grammar/primitives/PrimitivesDateTime.scala
##########
@@ -167,28 +193,38 @@ case class ConvertTextDatePrim(e: ElementBase) extends ConvertTextCalendarPrimBa
protected override val prettyType = "Date"
protected override val infosetPattern = "uuuu-MM-ddxxx"
protected override val implicitPattern = "uuuu-MM-dd"
- protected override val validFormatCharacters = "dDeEFGMuwWyXxYzZ".toSeq
+ protected override val validFormatCharacters =
+ if (e.representation == Representation.Binary) {
+ "dDeFMuwWyXxYZ".toSeq
+ } else {
+ "dDeEFGMuwWyXxYzZ".toSeq
+ }
}
case class ConvertTextTimePrim(e: ElementBase) extends ConvertTextCalendarPrimBase(e, true) {
protected override val xsdType = "time"
protected override val prettyType = "Time"
protected override val infosetPattern = "HH:mm:ss.SSSSSSxxx"
protected override val implicitPattern = "HH:mm:ssZ"
- protected override val validFormatCharacters = "ahHkKmsSvVzXxZ".toSeq
+ protected override val validFormatCharacters =
+ if (e.representation == Representation.Binary) {
+ "hHkKmsSXxZ".toSeq
+ } else {
+ "ahHkKmsSvVzXxZ".toSeq
Review comment:
Ditto steve's comment above about X and Z characters.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services