org.sakaiproject.entitybroker.entityprovider.extension
Class TemplateMap

java.lang.Object
  extended by org.sakaiproject.entitybroker.entityprovider.extension.TemplateMap

public class TemplateMap
extends Object

An object to hold the incoming and outgoing templates in pairs, used with RedirectDefinable

Author:
Aaron Zeckoski (azeckoski @ gmail.com)

Constructor Summary
TemplateMap(String incomingTemplate, String outgoingTemplate)
           
 
Method Summary
 String getIncomingTemplate()
           
 String getOutgoingTemplate()
           
 void setIncomingTemplate(String incomingTemplate)
           
 void setOutgoingTemplate(String outgoingTemplate)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TemplateMap

public TemplateMap(String incomingTemplate,
                   String outgoingTemplate)
Parameters:
incomingTemplate - the URL template pattern to match including the /prefix using {name} to indicate variables
Example: /{prefix}/{thing}/site/{siteId} will match the following URL:
/myprefix/123/site/456, the variables will be {prefix => myprefix, thing => 123, siteId => 456}
NOTE: all incoming URL templates must start with "/{prefix}" (TemplateParseUtil.TEMPLATE_PREFIX)
outgoingTemplate - the URL template pattern to fill with values from the incoming pattern, this can start with anything, but will be processed as an external redirect if it starts with "http" or "/" (unless it starts with "/{prefix}"), otherwise it will be processed as an internal forward
Method Detail

getIncomingTemplate

public String getIncomingTemplate()

setIncomingTemplate

public void setIncomingTemplate(String incomingTemplate)

getOutgoingTemplate

public String getOutgoingTemplate()

setOutgoingTemplate

public void setOutgoingTemplate(String outgoingTemplate)


Copyright © 2007-2012 Sakai Project. All Rights Reserved.