JavaScript Development Tools
Release 3.2

org.eclipse.wst.jsdt.core
Class BindingKey

java.lang.Object
  extended by org.eclipse.wst.jsdt.core.BindingKey

public final class BindingKey
extends Object

Utility class to decode or create a binding key.

This class is not intended to be subclassed by clients.

See Also:
Provisional API: This class/interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.

Constructor Summary
BindingKey(String key)
          Creates a new binding key.
 
Method Summary
static String createArrayTypeBindingKey(String typeKey, int arrayDimension)
          Creates a new array type binding key from the given type binding key and the given array dimension.
static String createTypeBindingKey(String typeName)
          Creates a new type binding key from the given type name.
 String toSignature()
          Transforms this binding key into a resolved signature.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BindingKey

public BindingKey(String key)
Creates a new binding key.

Parameters:
key - the key to decode
Method Detail

createArrayTypeBindingKey

public static String createArrayTypeBindingKey(String typeKey,
                                               int arrayDimension)
Creates a new array type binding key from the given type binding key and the given array dimension.

For example:

 
 createArrayTypeBindingKey("LObject;", 1) -> "[LObject;"
 
 

Note: This Method only applies to ECMAScript 4 which is not yet supported

Parameters:
typeKey - the binding key of the given type
arrayDimension - the given array dimension
Returns:
a new array type binding key

createTypeBindingKey

public static String createTypeBindingKey(String typeName)
Creates a new type binding key from the given type name.

For example:

 
 createTypeBindingKey("String") -> "LString;"
 
 

Note: This Method only applies to ECMAScript 4 which is not yet supported

Parameters:
typeName - the possibly qualified type name
Returns:
a new type binding key

toSignature

public String toSignature()
Transforms this binding key into a resolved signature. If this binding key represents a field, the returned signature is the declaring type's signature.

Returns:
the resolved signature for this binding key
See Also:
Signature

toString

public String toString()
Overrides:
toString in class Object

JavaScript Development Tools
Release 3.2

Copyright (c) IBM Corp. and others 2000, 2010. All Rights Reserved.