Class PickOmitMapping
- java.lang.Object
-
- com.broadleafcommerce.metadata.dsl.core.Mapping<PickOmitMapping>
-
- com.broadleafcommerce.metadata.dsl.core.extension.mappings.PickOmitMapping
-
- All Implemented Interfaces:
Copyable<PickOmitMapping>
,Serializable
public class PickOmitMapping extends Mapping<PickOmitMapping> implements Serializable
An implementation ofMapping
for picking and omitting source properties from the destination.- Author:
- Nick Crum (ncrum)
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description PickOmitMapping()
PickOmitMapping(PickOmitMapping mapping)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected boolean
canEqual(Object other)
PickOmitMapping
clearOmit()
Clears the set of omitted fields.PickOmitMapping
clearPick()
Clears the set of picked fields.PickOmitMapping
copy()
boolean
equals(Object o)
List<String>
getOmit()
The names of the properties that should not be kept from the source.List<String>
getPick()
The names of the properties that should be kept from the source.int
hashCode()
PickOmitMapping
omit(String... omit)
Sets the set of fields to exclude.PickOmitMapping
omit(List<String> omit)
Sets the set of fields to exclude.PickOmitMapping
pick(String... pick)
Sets the set of fields to include.PickOmitMapping
pick(List<String> pick)
Sets the set of fields to include.
-
-
-
Constructor Detail
-
PickOmitMapping
public PickOmitMapping()
-
PickOmitMapping
public PickOmitMapping(PickOmitMapping mapping)
-
-
Method Detail
-
copy
public PickOmitMapping copy()
- Specified by:
copy
in interfaceCopyable<PickOmitMapping>
- Returns:
- a deep copy of this instance
-
pick
public PickOmitMapping pick(List<String> pick)
Sets the set of fields to include.- Parameters:
pick
- the picked fields- Returns:
- the mapping
-
pick
public PickOmitMapping pick(String... pick)
Sets the set of fields to include.- Parameters:
pick
- the picked fields- Returns:
- the mapping
-
clearPick
public PickOmitMapping clearPick()
Clears the set of picked fields.- Returns:
- the mapping
-
omit
public PickOmitMapping omit(List<String> omit)
Sets the set of fields to exclude.- Parameters:
omit
- the omitted fields- Returns:
- the mapping
-
omit
public PickOmitMapping omit(String... omit)
Sets the set of fields to exclude.- Parameters:
omit
- the omitted fields- Returns:
- the mapping
-
clearOmit
public PickOmitMapping clearOmit()
Clears the set of omitted fields.- Returns:
- the mapping
-
getPick
public List<String> getPick()
The names of the properties that should be kept from the source.
-
getOmit
public List<String> getOmit()
The names of the properties that should not be kept from the source.
-
equals
public boolean equals(Object o)
- Overrides:
equals
in classMapping<PickOmitMapping>
-
canEqual
protected boolean canEqual(Object other)
- Overrides:
canEqual
in classMapping<PickOmitMapping>
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classMapping<PickOmitMapping>
-
-