package de.ivu.elect.business.wertelisten.entity;

import de.ivu.elect.jee.presentation.dynamicform.Property;

@javax.enterprise.inject.Vetoed
public class WertelistenProperties
{

private final Wertelisten entity;


    
    private
                de.ivu.elect.jee.presentation.dynamicform.LambdaStringProperty
                  nameProperty;

        
        
    private
                de.ivu.elect.jee.presentation.dynamicform.LambdaEnumProperty<de.ivu.elect.business.wertelisten.entity.WertelistenArt>
                  wertelistenArtProperty;

                private de.ivu.elect.jee.presentation.dynamicform.LambdaEnumProperty<de.ivu.elect.business.wertelisten.entity.WertelistenArt> wertelistenArtMitLeererAuswahlProperty;
        
    

public WertelistenProperties(Wertelisten entity) {
this.entity = entity;

}

private static WertelistenMeta getMetaData() {
return de.ivu.elect.jee.cdi.BeanManagerUtil.getBeanByClass( WertelistenMeta.class);
}


    

        public
                    de.ivu.elect.jee.presentation.dynamicform.AbstractStringProperty
                getNameProperty() {
        if (nameProperty == null) {
        nameProperty = new


                    de.ivu.elect.jee.presentation.dynamicform.LambdaStringProperty
        
        (
        getMetaData().getNameEinzahlMessage(),
        getMetaData().getNameDefaultValue(),
        getMetaData().isNameRequired(),
                entity::setName,
        entity::getName

                    ,  1 ,
            de.ivu.elect.business.wertelisten.entity.WertelistenConstants.NAME_MAX_LENGTH
                );

        }


        return nameProperty;
        }





        
        

        public
                    de.ivu.elect.jee.presentation.dynamicform.LambdaEnumProperty<de.ivu.elect.business.wertelisten.entity.WertelistenArt>
                getWertelistenArtProperty() {
        if (wertelistenArtProperty == null) {
        wertelistenArtProperty = new


                    de.ivu.elect.jee.presentation.dynamicform.LambdaEnumProperty<>
        
        (
        getMetaData().getWertelistenArtEinzahlMessage(),
        getMetaData().getWertelistenArtDefaultValue(),
        getMetaData().isWertelistenArtRequired(),
                entity::setWertelistenArt,
        entity::getWertelistenArt

                    , de.ivu.elect.business.wertelisten.entity.WertelistenArt.class,
            java.util.Arrays.asList(de.ivu.elect.business.wertelisten.entity.WertelistenArt.values()).stream().sorted(Enum::compareTo).collect(java.util.stream.Collectors.toList())
                );

        }


        return wertelistenArtProperty;
        }





        

            public de.ivu.elect.jee.presentation.dynamicform.LambdaEnumProperty<de.ivu.elect.business.wertelisten.entity.WertelistenArt> getWertelistenArtMitLeererAuswahlProperty() {
               if (wertelistenArtMitLeererAuswahlProperty == null) {
                 wertelistenArtMitLeererAuswahlProperty = new
                de.ivu.elect.jee.presentation.dynamicform.LambdaEnumProperty<>
                    (
                        getMetaData().getWertelistenArtEinzahlMessage(),
        				getMetaData().getWertelistenArtDefaultValue(),
                        getMetaData().isWertelistenArtRequired(),
                        entity::setWertelistenArt,
                        entity::getWertelistenArt
                        , de.ivu.elect.business.wertelisten.entity.WertelistenArt.class,
                        java.util.Arrays.asList(de.ivu.elect.business.wertelisten.entity.WertelistenArt.values()).stream().sorted(Enum::compareTo).collect(java.util.stream.Collectors.toList())
                        ,true
                    );
            }

               return wertelistenArtMitLeererAuswahlProperty;
            }
        
        }