Package com.palantir.ptoss.cinch.core
Class WeakBindableModelSupport
- java.lang.Object
- 
- com.palantir.ptoss.cinch.core.WeakBindableModelSupport
 
- 
- All Implemented Interfaces:
- BindableModel
 
 public class WeakBindableModelSupport extends java.lang.Object implements BindableModel A stand-alone implementation ofBindableModel. UsesWeakReferences to attach bindings to models.
- 
- 
Constructor SummaryConstructors Constructor Description WeakBindableModelSupport()
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidbind(Binding binding)Attach the binding to the model.<T extends java.lang.Enum<T> & ModelUpdate>
 voidmodelUpdated(T... changed)Alert the bindings that the model has updated with the specified change types.voidunbind(Binding toUnbind)Removes the passed binding from this model.voidunbindAll()Removes all bindings from this model.voidupdate()Shortcut call for a generic model update.
 
- 
- 
- 
Method Detail- 
bindpublic void bind(Binding binding) Attach the binding to the model. Whenever the model is updated then the binding will be triggered.- Specified by:
- bindin interface- BindableModel
 
 - 
updatepublic void update() Shortcut call for a generic model update.
 - 
modelUpdatedpublic <T extends java.lang.Enum<T> & ModelUpdate> void modelUpdated(T... changed) Alert the bindings that the model has updated with the specified change types.- Specified by:
- modelUpdatedin interface- BindableModel
- Parameters:
- changed- list of change types to indicate
 
 - 
unbindpublic void unbind(Binding toUnbind) Removes the passed binding from this model.- Specified by:
- unbindin interface- BindableModel
 
 - 
unbindAllpublic void unbindAll() Removes all bindings from this model.
 
- 
 
-