public abstract class AbstractNamingScheme extends Object implements NamingScheme
| Constructor and Description |
|---|
AbstractNamingScheme(String delimiter)
Create a new Prefixer.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
accept(String id)
Determine if this identifier has been prefixed
|
Collection<BeanIdentifier> |
deprefix(Collection<String> ids) |
BeanIdentifier |
deprefix(String id)
Remove the prefix from the id
|
Collection<String> |
filterIds(Collection<String> ids)
Filter a collection of ids, retaining only those correctly prefixed.
|
protected String |
getDelimiter() |
protected abstract String |
getPrefix() |
String |
prefix(BeanIdentifier id)
Add the prefix to the id
|
Collection<String> |
prefix(Collection<BeanIdentifier> ids) |
public AbstractNamingScheme(String delimiter)
prefix - The prefixdelimiter - The delimiter to use between the prefix and the
identifier.public boolean accept(String id)
NamingSchemeaccept in interface NamingSchemeid - the id to checkpublic BeanIdentifier deprefix(String id)
NamingSchemedeprefix in interface NamingSchemeid - the prefixed idpublic String prefix(BeanIdentifier id)
NamingSchemeprefix in interface NamingSchemeid - the id to prefixpublic Collection<String> filterIds(Collection<String> ids)
NamingSchemefilterIds in interface NamingSchemeids - the collection of ides to filterpublic Collection<BeanIdentifier> deprefix(Collection<String> ids)
deprefix in interface NamingSchemepublic Collection<String> prefix(Collection<BeanIdentifier> ids)
prefix in interface NamingSchemeprotected abstract String getPrefix()
protected String getDelimiter()
Copyright © 2015. All Rights Reserved.