Class NameUnmarshallerReceptacle<T>


  • public class NameUnmarshallerReceptacle<T>
    extends java.lang.Object
    • Constructor Detail

      • NameUnmarshallerReceptacle

        public NameUnmarshallerReceptacle​(java.lang.String name,
                                          Unmarshaller<java.lang.String,​T> um)
    • Method Detail

      • as

        public <B> NameUnmarshallerReceptacle<B> as​(Unmarshaller<T,​B> unmarshaller)
        Extract the value as the specified type. You need a matching Unmarshaller in scope for that to work.
        Parameters:
        unmarshaller - (undocumented)
        Returns:
        (undocumented)
      • name

        public java.lang.String name()
      • requiredValue

        public RequiredValueUnmarshallerReceptacle<T> requiredValue​(T requiredValue)
        Require the given value and extract nothing. Reject if it is missing or has a different value.
        Parameters:
        requiredValue - (undocumented)
        Returns:
        (undocumented)
      • withDefault

        public NameDefaultUnmarshallerReceptacle<T> withDefault​(T default_)
        Extract the optional value as T, if it is missing use the given default value.
        Parameters:
        default_ - (undocumented)
        Returns:
        (undocumented)