Class GeoPosition.Builder
- java.lang.Object
-
- com.anaptecs.jeaf.junit.openapi.base.PlaceRef.Builder
-
- com.anaptecs.jeaf.junit.openapi.base.GeoPosition.Builder
-
- Direct Known Subclasses:
SwissGeoPosition.Builder
- Enclosing class:
- GeoPosition
public static class GeoPosition.Builder extends PlaceRef.Builder
Class implements builder to create a new instance of classGeoPosition.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedBuilder()UseGeoPosition.builder()instead of private constructor to create new builder.protectedBuilder(GeoPosition pObject)UseGeoPosition.builder(GeoPosition)instead of private constructor to create new builder.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description GeoPositionbuild()Method creates a new instance of class GeoPosition.GeoPositionbuildValidated()Method creates a new validated instance of class GeoPosition.GeoPosition.BuildersetLatitude(int pLatitude)Method sets attributelatitude.GeoPosition.BuildersetLongitude(int pLongitude)Method sets attributelongitude.GeoPosition.BuildersetName(java.lang.String pName)Method sets attributePlaceRef.name.
-
-
-
Constructor Detail
-
Builder
protected Builder()
UseGeoPosition.builder()instead of private constructor to create new builder.
-
Builder
protected Builder(GeoPosition pObject)
UseGeoPosition.builder(GeoPosition)instead of private constructor to create new builder.
-
-
Method Detail
-
setName
public GeoPosition.Builder setName(java.lang.String pName)
Method sets attributePlaceRef.name.- Overrides:
setNamein classPlaceRef.Builder- Parameters:
pName- Value to whichPlaceRef.nameshould be set.- Returns:
GeoPosition.BuilderInstance of this builder to support chaining setters. Method never returns null.
-
setLongitude
public GeoPosition.Builder setLongitude(int pLongitude)
Method sets attributelongitude.- Parameters:
pLongitude- Value to whichlongitudeshould be set.- Returns:
GeoPosition.BuilderInstance of this builder to support chaining setters. Method never returns null.
-
setLatitude
public GeoPosition.Builder setLatitude(int pLatitude)
Method sets attributelatitude.- Parameters:
pLatitude- Value to whichlatitudeshould be set.- Returns:
GeoPosition.BuilderInstance of this builder to support chaining setters. Method never returns null.
-
build
public GeoPosition build()
Method creates a new instance of class GeoPosition. The object will be initialized with the values of the builder.- Returns:
- GeoPosition Created object. The method never returns null.
-
buildValidated
public GeoPosition buildValidated() throws javax.validation.ConstraintViolationException
Method creates a new validated instance of class GeoPosition. The object will be initialized with the values of the builder and validated afterwards.- Returns:
- GeoPosition 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.
-
-