net.sf.morph.lang.languages
Class LanguageDecorator

java.lang.Object
  extended by net.sf.morph.lang.languages.BaseLanguage
      extended by net.sf.morph.lang.languages.LanguageDecorator
All Implemented Interfaces:
DecoratedLanguage, Language

public class LanguageDecorator
extends BaseLanguage
implements DecoratedLanguage

Decorates any language so that it implements DecoratedLanguage.

Since:
Nov 28, 2004
Author:
Matt Sgarlata

Constructor Summary
LanguageDecorator()
          Create a new LanguageDecorator.
LanguageDecorator(Language language)
          Create a new LanguageDecorator.
 
Method Summary
protected  java.lang.Object getImpl(java.lang.Object target, java.lang.String expression)
          Implement get(target, expression).
 Language getLanguage()
          Get the decorated language.
protected  java.lang.Class getTypeImpl(java.lang.Object target, java.lang.String expression)
          Implement getType(target, expression).
protected  boolean isPropertyImpl(java.lang.String expression)
          Implement isProperty(expression).
protected  void setImpl(java.lang.Object target, java.lang.String expression, java.lang.Object value)
          Implement set(target, expression, value).
 void setLanguage(Language language)
          Set the decorated language.
 
Methods inherited from class net.sf.morph.lang.languages.BaseLanguage
get, get, get, get, getConverter, getLanguageName, getType, isProperty, set, set, setConverter, setLanguageName, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface net.sf.morph.lang.DecoratedLanguage
get, get, get, set, set
 
Methods inherited from interface net.sf.morph.lang.Language
get, getType, isProperty
 

Constructor Detail

LanguageDecorator

public LanguageDecorator()
Create a new LanguageDecorator.


LanguageDecorator

public LanguageDecorator(Language language)
Create a new LanguageDecorator.

Parameters:
language - to decorate
Method Detail

getImpl

protected java.lang.Object getImpl(java.lang.Object target,
                                   java.lang.String expression)
                            throws LanguageException
Implement get(target, expression).

Specified by:
getImpl in class BaseLanguage
Parameters:
target - bean
expression - to get
Returns:
Object
Throws:
LanguageException

getTypeImpl

protected java.lang.Class getTypeImpl(java.lang.Object target,
                                      java.lang.String expression)
                               throws LanguageException
Implement getType(target, expression).

Specified by:
getTypeImpl in class BaseLanguage
Parameters:
target - bean
expression - to read
Returns:
Class
Throws:
LanguageException

setImpl

protected void setImpl(java.lang.Object target,
                       java.lang.String expression,
                       java.lang.Object value)
                throws java.lang.Exception
Implement set(target, expression, value).

Specified by:
setImpl in class BaseLanguage
Parameters:
target - bean
expression - to set
value - to set
Throws:
java.lang.Exception

isPropertyImpl

protected boolean isPropertyImpl(java.lang.String expression)
Implement isProperty(expression).

Specified by:
isPropertyImpl in class BaseLanguage
Returns:
boolean

getLanguage

public Language getLanguage()
Get the decorated language.

Returns:
Language

setLanguage

public void setLanguage(Language language)
Set the decorated language.

Parameters:
language - to set


Copyright © 2004-2008.