Search in sources :

Example 1 with ValueModelAttribute

use of org.robobinding.attribute.ValueModelAttribute in project RoboBinding by RoboBinding.

the class OneWayBindingPropertyTest method aBoundProperty.

private OneWayBindingProperty aBoundProperty() {
    ValueModelAttribute attribute = aValueModelAttribute(PROPERTY_NAME);
    OneWayBindingProperty bindingProperty = new OneWayBindingProperty(view, viewAttributeSpy, attribute);
    BindingContext bindingContext = aBindingContextWithReadOnlyProperty(PROPERTY_NAME, valueModel);
    bindingProperty.performBind(bindingContext);
    return bindingProperty;
}
Also used : ValueModelAttribute(org.robobinding.attribute.ValueModelAttribute) Attributes.aValueModelAttribute(org.robobinding.attribute.Attributes.aValueModelAttribute) BindingContext(org.robobinding.BindingContext)

Example 2 with ValueModelAttribute

use of org.robobinding.attribute.ValueModelAttribute in project RoboBinding by RoboBinding.

the class TwoWayBindingPropertyTest method aBoundProperty.

private TwoWayBindingProperty aBoundProperty(ValueModel<Integer> valueModel) {
    ValueModelAttribute attribute = aValueModelAttribute(PROPERTY_NAME);
    TwoWayBindingProperty bindingProperty = new TwoWayBindingProperty(view, viewAddOn, viewAttributeSpy, attribute);
    BindingContext bindingContext = aBindingContextWithProperty(PROPERTY_NAME, valueModel);
    bindingProperty.performBind(bindingContext);
    return bindingProperty;
}
Also used : ValueModelAttribute(org.robobinding.attribute.ValueModelAttribute) Attributes.aValueModelAttribute(org.robobinding.attribute.Attributes.aValueModelAttribute) BindingContext(org.robobinding.BindingContext)

Example 3 with ValueModelAttribute

use of org.robobinding.attribute.ValueModelAttribute in project RoboBinding by RoboBinding.

the class ChildViewAttributesBuilderImpl method add.

@Override
public void add(String attributeName, OneWayPropertyViewAttribute<ViewType, ?> viewAttribute) {
    ValueModelAttribute attribute = resolvedGroupAttributes.valueModelAttributeFor(attributeName);
    PropertyViewAttributeBinder viewAttributeBinder = viewAttributeBinderFactory.binderFor(viewAttribute, attribute);
    childViewAttributeMap.put(attributeName, viewAttributeBinder);
}
Also used : ValueModelAttribute(org.robobinding.attribute.ValueModelAttribute) PropertyViewAttributeBinder(org.robobinding.viewattribute.property.PropertyViewAttributeBinder) MultiTypePropertyViewAttributeBinder(org.robobinding.viewattribute.property.MultiTypePropertyViewAttributeBinder)

Example 4 with ValueModelAttribute

use of org.robobinding.attribute.ValueModelAttribute in project RoboBinding by RoboBinding.

the class ChildViewAttributesBuilderImpl method add.

@Override
public void add(String attributeName, TwoWayPropertyViewAttribute<ViewType, ?, ?> viewAttribute) {
    ValueModelAttribute attribute = resolvedGroupAttributes.valueModelAttributeFor(attributeName);
    PropertyViewAttributeBinder viewAttributeBinder = viewAttributeBinderFactory.binderFor(viewAttribute, attribute);
    childViewAttributeMap.put(attributeName, viewAttributeBinder);
}
Also used : ValueModelAttribute(org.robobinding.attribute.ValueModelAttribute) PropertyViewAttributeBinder(org.robobinding.viewattribute.property.PropertyViewAttributeBinder) MultiTypePropertyViewAttributeBinder(org.robobinding.viewattribute.property.MultiTypePropertyViewAttributeBinder)

Example 5 with ValueModelAttribute

use of org.robobinding.attribute.ValueModelAttribute in project RoboBinding by RoboBinding.

the class ChildViewAttributesBuilderImpl method add.

@Override
public void add(String propertyAttribute, OneWayPropertyViewAttributeFactory<ViewType> factory) {
    ValueModelAttribute attribute = resolvedGroupAttributes.valueModelAttributeFor(propertyAttribute);
    PropertyViewAttributeBinder viewAttributeBinder = viewAttributeBinderFactory.binderFor(factory, attribute);
    childViewAttributeMap.put(propertyAttribute, viewAttributeBinder);
}
Also used : ValueModelAttribute(org.robobinding.attribute.ValueModelAttribute) PropertyViewAttributeBinder(org.robobinding.viewattribute.property.PropertyViewAttributeBinder) MultiTypePropertyViewAttributeBinder(org.robobinding.viewattribute.property.MultiTypePropertyViewAttributeBinder)

Aggregations

ValueModelAttribute (org.robobinding.attribute.ValueModelAttribute)12 MultiTypePropertyViewAttributeBinder (org.robobinding.viewattribute.property.MultiTypePropertyViewAttributeBinder)10 PropertyViewAttributeBinder (org.robobinding.viewattribute.property.PropertyViewAttributeBinder)5 BindingContext (org.robobinding.BindingContext)2 Attributes.aValueModelAttribute (org.robobinding.attribute.Attributes.aValueModelAttribute)2 MultiTypePropertyViewAttributeBinderFactory (org.robobinding.viewattribute.property.MultiTypePropertyViewAttributeBinderFactory)2 PropertyViewAttributeBinderFactory (org.robobinding.viewattribute.property.PropertyViewAttributeBinderFactory)1