ilog.tgo.css.function
Class IltLinkPortFunction

java.lang.Object
  extended by ilog.views.util.styling.IlvCSSFunction
      extended by ilog.tgo.css.function.IltLinkPortFunction
All Implemented Interfaces:
Serializable

public class IltLinkPortFunction
extends IlvCSSFunction

IltLinkPortFunction is a function to create or retrieve link ports.

The function should be defined as follows:

   linkPorts[0] : '@|linkPort("Top")';
   linkPorts[1] : '@|linkPort("RightAboveMiddle", 1.0f, 0.2f, 1, 0, -1)';
   linkPorts[2] : '@|linkPort("RightBelowMiddle", 1.0f, 0.8f, 1, 0, -1)';
 
This definition creates a link port with the corresponding configuration. If a link port with the given name already exists, it is returned despite the value of the remaining arguments. The first argument is mandatory and is the name of the link port. The following arguments are optional:

Note: The function must be fully quoted in order to be parsed correctly. If the function argument is not valid or cannot be parsed, an IllegalArgumentException is thrown.

Since:
JTGO 4.5
See Also:
Serialized Form

Constructor Summary
IltLinkPortFunction()
          The default constructor.
 
Method Summary
 Object call(Object[] args, Class type, ilog.views.util.css.IlvCSSModel model, Object node, Object target, Object closure)
          Called to execute the function.
 String getDelimiters()
          Returns the function parameter delimiter.
 String getName()
          Retrieves the name of the function.
 boolean returnDelimitersAsToken()
          If the delimiters are also returned as a token, true is returned.
 
Methods inherited from class ilog.views.util.styling.IlvCSSFunction
getImportance, getShortDescription
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IltLinkPortFunction

public IltLinkPortFunction()
The default constructor.

Method Detail

getName

public String getName()
Retrieves the name of the function.

Specified by:
getName in class IlvCSSFunction
Returns:
This method always returns "linkPort".

getDelimiters

public String getDelimiters()
Returns the function parameter delimiter.

Overrides:
getDelimiters in class IlvCSSFunction
Returns:
A string containing the accepted delimiters for this function. The delimiter is ",".

returnDelimitersAsToken

public boolean returnDelimitersAsToken()
If the delimiters are also returned as a token, true is returned.

Overrides:
returnDelimitersAsToken in class IlvCSSFunction
Returns:
This function always returns false.

call

public Object call(Object[] args,
                   Class type,
                   ilog.views.util.css.IlvCSSModel model,
                   Object node,
                   Object target,
                   Object closure)
Called to execute the function.

Specified by:
call in class IlvCSSFunction
Parameters:
args - The list of arguments passed to the function.
type - The expected type of the object that will be returned by the function.
model - The CSS model being used.
node - The current model object being called on.
target - The target object where the returned object will be applied.
closure - An object set by IlvCSSBeans.setFunctionClosure(java.lang.Object)
Returns:
The value computed by this function. This is a Color.


Copyright © 1996-2007 ILOG S.A. All rights reserved.   Documentation homepage.   . All Rights Reserved.