Search in sources :

Example 1 with EventTypeMatcherModel

use of com.infiniteautomation.mango.rest.latest.model.event.EventTypeMatcherModel in project ma-modules-public by infiniteautomation.

the class AbstractEventHandlerModel method fromVO.

@Override
public void fromVO(T vo) {
    super.fromVO(vo);
    this.disabled = vo.isDisabled();
    this.readPermission = new MangoPermissionModel(vo.getReadPermission());
    this.editPermission = new MangoPermissionModel(vo.getEditPermission());
    this.eventTypes = vo.getEventTypes().stream().map(EventTypeMatcherModel::new).collect(Collectors.toList());
}
Also used : MangoPermissionModel(com.infiniteautomation.mango.rest.latest.model.permissions.MangoPermissionModel) EventTypeMatcherModel(com.infiniteautomation.mango.rest.latest.model.event.EventTypeMatcherModel)

Aggregations

EventTypeMatcherModel (com.infiniteautomation.mango.rest.latest.model.event.EventTypeMatcherModel)1 MangoPermissionModel (com.infiniteautomation.mango.rest.latest.model.permissions.MangoPermissionModel)1