Package sc.type

Class BeanMapper

    • Field Detail

      • field

        public java.lang.reflect.Field field
        if the bean has both get/set and fields, this is set to the field
      • getSelector

        protected java.lang.Object getSelector
      • setSelector

        protected java.lang.Object setSelector
      • validateMethod

        protected java.lang.Object validateMethod
      • instPosition

        public int instPosition
      • staticPosition

        public int staticPosition
      • getIsField

        public boolean getIsField
      • setIsField

        public boolean setIsField
      • constant

        public boolean constant
      • isPrimitive

        public boolean isPrimitive
      • ownerType

        public java.lang.Object ownerType
    • Constructor Detail

      • BeanMapper

        public BeanMapper()
      • BeanMapper

        public BeanMapper​(BeanMapper base)
      • BeanMapper

        public BeanMapper​(java.lang.Object get,
                          java.lang.Object set,
                          java.lang.reflect.Field fld)
    • Method Detail

      • getPropertyValue

        public java.lang.Object getPropertyValue​(java.lang.Object parent,
                                                 boolean getField,
                                                 boolean pendingChild)
        Description copied from interface: IBinding
        Retrieves the current value of the binding given the current object. Use getField = true to force use of the field, rather than the getX method if one exists. Use pendingChild = true for a special case where we are getting the property value of a binding that is part of a reverse binding but where the cached value is up-to-update because we are updating a child remote property.
      • setPropertyValue

        public void setPropertyValue​(java.lang.Object parent,
                                     java.lang.Object value)
        Description copied from interface: IBeanMapper
        Sets a specific property on the specified object
      • getField

        public java.lang.reflect.Field getField()
      • hasAccessorMethod

        public boolean hasAccessorMethod()
      • setGetSelector

        public void setGetSelector​(java.lang.Object gs)
      • getGetSelector

        public java.lang.Object getGetSelector()
      • getSetSelector

        public java.lang.Object getSetSelector()
      • setSetSelector

        public void setSetSelector​(java.lang.Object gs)
      • isPropertyIs

        public boolean isPropertyIs()
      • hasSetterMethod

        public boolean hasSetterMethod()
      • getPropertyName

        public java.lang.String getPropertyName()
      • getPropertyType

        public java.lang.Class getPropertyType()
      • getGenericType

        public java.lang.reflect.Type getGenericType()
      • getGenericTypeName

        public java.lang.String getGenericTypeName​(java.lang.Object resultType,
                                                   boolean includeDims)
      • getPropertyMember

        public java.lang.reflect.Member getPropertyMember()
      • getPropertySetter

        public java.lang.Object getPropertySetter()
      • getPropertyPosition

        public int getPropertyPosition()
      • getPropertyPosition

        public int getPropertyPosition​(java.lang.Object obj)
      • getStaticPropertyPosition

        public int getStaticPropertyPosition()
      • performCast

        public java.lang.Object performCast​(java.lang.Object val)
        Called before the apply reverse binding. Here we need to do Number type conversion since there is no way to specify this cast statically. The value passed to applyReverse binding will be this value. To prevent unnecessary firings, we need to save the converted value in the parent.
        Specified by:
        performCast in interface IBinding
        Specified by:
        performCast in class AbstractBeanMapper
      • setConstant

        public void setConstant​(boolean val)
        Description copied from interface: IBeanMapper
        Forces a property mapping to be treated as constant, i.e. attempts to change it will result in an error, no need to listen for changes
      • isScalarToList

        public boolean isScalarToList()
      • getComponentType

        public java.lang.Class getComponentType()
        Returns the type of the first type argument or java.lang.Object.class if none
      • clone

        public BeanMapper clone()
        clone in class java.lang.Object
      • getOwnerType

        public java.lang.Object getOwnerType()
      • setValidateMethod

        public void setValidateMethod​(java.lang.Object validateMethod)
      • getValidateMethod

        public java.lang.Object getValidateMethod()