Class Channel.Builder
- java.lang.Object
-
- com.anaptecs.jeaf.junit.openapi.base.Channel.Builder
-
- Enclosing class:
- Channel
public static class Channel.Builder extends java.lang.ObjectClass implements builder to create a new instance of classChannel.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedBuilder()UseChannel.builder()instead of private constructor to create new builder.protectedBuilder(Channel pObject)UseChannel.builder(Channel)instead of private constructor to create new builder.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Channelbuild()Method creates a new instance of class Channel.ChannelbuildValidated()Method creates a new validated instance of class Channel.Channel.BuildersetChannelCode(ChannelCode pChannelCode)Method sets associationchannelCode.Channel.BuildersetChannelType(ChannelType pChannelType)Method sets associationchannelType.Channel.BuildersetCode(int pCode)Method sets attributecode.Channel.BuildersetReseller(Reseller pReseller)Method sets associationreseller.Channel.BuildersetSelfServiceChannel(boolean pSelfServiceChannel)Method sets attributeselfServiceChannel.
-
-
-
Constructor Detail
-
Builder
protected Builder()
UseChannel.builder()instead of private constructor to create new builder.
-
Builder
protected Builder(Channel pObject)
UseChannel.builder(Channel)instead of private constructor to create new builder.
-
-
Method Detail
-
setChannelType
public Channel.Builder setChannelType(ChannelType pChannelType)
Method sets associationchannelType.- Parameters:
pChannelType- Value to whichchannelTypeshould be set.- Returns:
Channel.BuilderInstance of this builder to support chaining setters. Method never returns null.
-
setChannelCode
public Channel.Builder setChannelCode(ChannelCode pChannelCode)
Method sets associationchannelCode.- Parameters:
pChannelCode- Value to whichchannelCodeshould be set.- Returns:
Channel.BuilderInstance of this builder to support chaining setters. Method never returns null.
-
setCode
public Channel.Builder setCode(int pCode)
Method sets attributecode.- Parameters:
pCode- Value to whichcodeshould be set.- Returns:
Channel.BuilderInstance of this builder to support chaining setters. Method never returns null.
-
setSelfServiceChannel
public Channel.Builder setSelfServiceChannel(boolean pSelfServiceChannel)
Method sets attributeselfServiceChannel.- Parameters:
pSelfServiceChannel- Value to whichselfServiceChannelshould be set.- Returns:
Channel.BuilderInstance of this builder to support chaining setters. Method never returns null.
-
setReseller
public Channel.Builder setReseller(Reseller pReseller)
Method sets associationreseller.- Parameters:
pReseller- Value to whichresellershould be set.- Returns:
Channel.BuilderInstance of this builder to support chaining setters. Method never returns null.
-
build
public Channel build()
Method creates a new instance of class Channel. The object will be initialized with the values of the builder.- Returns:
- Channel Created object. The method never returns null.
-
buildValidated
public Channel buildValidated() throws javax.validation.ConstraintViolationException
Method creates a new validated instance of class Channel. The object will be initialized with the values of the builder and validated afterwards.- Returns:
- Channel Created and validated object. The method never returns null.
- Throws:
javax.validation.ConstraintViolationException- in case that one or more validations for the created object failed.
-
-