public class AbstractUserPreferenceDescriptor<T extends UserPreferenceDescriptor<?>> extends Object implements UserPreferenceDescriptor<T>
Constructor and Description |
---|
AbstractUserPreferenceDescriptor(String userPreferenceName,
UserPreferenceContainerDescriptor container) |
Modifier and Type | Method and Description |
---|---|
UserPreferenceContainerDescriptor |
and()
Describes addition of a new user preference descriptor for the parent
UserPreferenceContainerDescriptor . |
T |
byId()
Describes if the configuration element is referenced by id in this user preference.
|
T |
byKey()
Describes if the configuration element is referenced by key in this user preference.
|
T |
byName()
Describes if the configuration element is referenced by name in this user preference.
|
Set<String> |
getLiteralValues() |
String |
getReferenceValuePrefix() |
ReferenceValueType |
getReferenceValueType() |
String |
getUserPreferenceName() |
UserPreferenceType |
getUserPreferenceType() |
T |
ofType(UserPreferenceType userPreferenceType)
Describes the type of a referenced configuration element in this user preference.
|
T |
withLiteralValues(String... literalValues)
Describes the literal values of this user preference that should be moved as-is.
|
T |
withPrefix(String prefix)
Describes that the configuration element is referenced by value with prefix in this user preference.
|
public AbstractUserPreferenceDescriptor(String userPreferenceName, UserPreferenceContainerDescriptor container)
public UserPreferenceContainerDescriptor and()
UserPreferenceDescriptor
UserPreferenceContainerDescriptor
.and
in interface UserPreferenceDescriptor<T extends UserPreferenceDescriptor<?>>
UserPreferenceContainerDescriptor
instance.public T ofType(UserPreferenceType userPreferenceType)
UserPreferenceDescriptor
ofType
in interface UserPreferenceDescriptor<T extends UserPreferenceDescriptor<?>>
userPreferenceType
- the type of a referenced configuration element in this user preference.public T byId()
UserPreferenceDescriptor
UserPreferenceType.USER
this method
will behave in the same way as UserPreferenceDescriptor.byKey()
.byId
in interface UserPreferenceDescriptor<T extends UserPreferenceDescriptor<?>>
public T byName()
UserPreferenceDescriptor
byName
in interface UserPreferenceDescriptor<T extends UserPreferenceDescriptor<?>>
public T byKey()
UserPreferenceDescriptor
UserPreferenceType.PROJECT
and UserPreferenceType.USER
. For all other configuration elements this method will
behave in the same way as UserPreferenceDescriptor.byId()
.byKey
in interface UserPreferenceDescriptor<T extends UserPreferenceDescriptor<?>>
public T withPrefix(String prefix)
UserPreferenceDescriptor
withPrefix
in interface UserPreferenceDescriptor<T extends UserPreferenceDescriptor<?>>
prefix
- the prefix of the valuepublic T withLiteralValues(String... literalValues)
UserPreferenceDescriptor
withLiteralValues
in interface UserPreferenceDescriptor<T extends UserPreferenceDescriptor<?>>
literalValues
- literal values of this user preference.public String getUserPreferenceName()
public UserPreferenceType getUserPreferenceType()
public ReferenceValueType getReferenceValueType()
public String getReferenceValuePrefix()
Copyright © 2022. All rights reserved.