Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.apache.hivemind.schema.rules
Class ResourceTranslator  view ResourceTranslator download ResourceTranslator.java

java.lang.Object
  extended byorg.apache.hivemind.schema.rules.ResourceTranslator
All Implemented Interfaces:
org.apache.hivemind.schema.Translator

public class ResourceTranslator
extends java.lang.Object
implements org.apache.hivemind.schema.Translator

Translator that converts the value to be a resource relative to the contributing module's deployment descriptor.


Constructor Summary
ResourceTranslator()
           
 
Method Summary
 java.lang.Object translate(org.apache.hivemind.internal.Module contributingModule, java.lang.Class propertyType, java.lang.String inputValue, org.apache.hivemind.Location location)
          Finds the resource.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResourceTranslator

public ResourceTranslator()
Method Detail

translate

public java.lang.Object translate(org.apache.hivemind.internal.Module contributingModule,
                                  java.lang.Class propertyType,
                                  java.lang.String inputValue,
                                  org.apache.hivemind.Location location)
Finds the resource. If the inputValue is blank, then returns null. Interprets the inputValue as a relative path from the contributing module's descriptor. In addition, a localized resource will be returned if avaiable (localized to the registry's locale 55 .

Specified by:
translate in interface org.apache.hivemind.schema.Translator