OracleJavaScript API Reference for Oracle ADF Faces

 

SUMMARY: FIELD | CONSTR | METHOD    DETAIL: FIELD | CONSTR | METHOD

oracle.adf.view.js.datatransfer
Class AdfObjectTransferable

org.ecmascript.object.Object
   |
   +--oracle.adf.view.js.base.AdfObject
         |
         +--oracle.adf.view.js.datatransfer.AdfTransferable
               |
               +--oracle.adf.view.js.datatransfer.AdfObjectTransferable

public class AdfObjectTransferable
extends AdfTransferable
Creates an AdfObjectAdfTransferable from an Array of alternative instances of the Objects to transfer, and optionally an Array of the AdfDataFlavors for each of those Objects. If the AdfDataFlavors are not provided, they will be calculated from the Object instances. Even if the dataFlavors array is provided, it is allowed to contain null for flavors that should be dynamically determined off of the data Objects.



Field Summary

private Object
_baseObjects
private Object
_converters
private Object
_dataFlavors
private Object
_objectsForFlavors


Fields inherited from oracle.adf.view.js.base.AdfObject

constructor, superclass


Fields inherited from org.ecmascript.object.Object

prototype


Constructor Summary

public
AdfObjectTransferable(Object objectsForFlavors, Object dataFlavors, Object baseObjects, Object converters)
Creates an AdfObjectAdfTransferable from an Array of alternative instances of the Objects to transfer, and optionally an Array of the AdfDataFlavors for each of those Objects.


Method Summary

private static Object
_addFlavorIfNecessary(AdfDataFlavor dataFlavor, Object associativeFlavors, Object dataObjectIndex)
Adds the DataFlavor to the associateFlavors associative array if it isn't already present in the array
private static Object
_addSuperclassFlavors(Object baseDataFlavor, Object associativeFlavors, Object dataObjectIndex)
private static Object
_createDataFlavors(Object objectsForFlavors, Object dataFlavors)
Returns an associative array of dataflavors and the index of the corresponding Javascript objects
public static Object
createMultiObjectTransferable(Object dataObjects, Object dataFlavor)
Creates an AdfObjectAdfTransferable representing multiple objects with the same AdfDataFlavor.
public static AdfObjectTransferable
createSingleObjectTransferable(Object data, Object dataFlavor)
Creates an AdfObjectAdfTransferable from an instance of the Object to transfer, and optionally an instance of the AdfDataFlavor for the Object.
public Object
getTransferData(AdfDataFlavor dataFlavor)
Returns the array of data objects for this AdfDataFlavor, or null if no data for the specified AdfDataFlavor is available
public Object
getTransferDataFlavors()
Returns the array of AdfDataFlavors for which this AdfTransferable has data.
protected Object
Init(Array objectsForFlavors, Array<AdfDataFlavor> dataFlavors, Array baseObjects, Array<Function> converters)
Initializes the instance.
public Object
isDataFlavorSupported(Object dataFlavor)
Returns true if the AdfTransferable contains data for the specified AdfDataFlavor
public Object
toDebugString()


Methods inherited from oracle.adf.view.js.base.AdfObject

adopt, clone, createCallback, createInitializedObject, createSubclass, ensureClassInitialization, equals, getClass, GetLazyArrayProperty, GetLazyMapProperty, getTypeName, toString


Field Detail


_baseObjects

private Object _baseObjects

_converters

private Object _converters

_dataFlavors

private Object _dataFlavors

_objectsForFlavors

private Object _objectsForFlavors

Constructor Detail


AdfObjectTransferable

public AdfObjectTransferable(Object objectsForFlavors,
                             Object dataFlavors,
                             Object baseObjects,
                             Object converters)

Creates an AdfObjectAdfTransferable from an Array of alternative instances of the Objects to transfer, and optionally an Array of the AdfDataFlavors for each of those Objects. If the AdfDataFlavors are not provided, they will be calculated from the Object instances. Even if the dataFlavors array is provided, it is allowed to contain null for flavors that should be dynamically determined off of the data Objects.

Parameters:
objectsForFlavors  -  Array of Arrays. The Arrays are arranged as follows [0] Array of Objects to transfer for AdfDataFlavor dataFlavors[0] [1] Array of Objects to transfer for AdfDataFlavor dataFlavors[1] [x] Array of Objects to transfer for AdfDataFlavor dataFlavors[x]
dataFlavors    
baseObjects    
converters    

Method Detail


_addFlavorIfNecessary

private static Object _addFlavorIfNecessary(AdfDataFlavor dataFlavor,
                                            Object associativeFlavors,
                                            Object dataObjectIndex)

Adds the DataFlavor to the associateFlavors associative array if it isn't already present in the array

Parameters:
dataFlavor  -  DataFlavor to add
associativeFlavors    
dataObjectIndex    
Return:
Object

_addSuperclassFlavors

private static Object _addSuperclassFlavors(Object baseDataFlavor,
                                            Object associativeFlavors,
                                            Object dataObjectIndex)

Parameters:
baseDataFlavor    
associativeFlavors    
dataObjectIndex    
Return:
Object

_createDataFlavors

private static Object _createDataFlavors(Object objectsForFlavors,
                                         Object dataFlavors)

Returns an associative array of dataflavors and the index of the corresponding Javascript objects

Parameters:
objectsForFlavors    
dataFlavors    
Return:
Object

createMultiObjectTransferable

public static Object createMultiObjectTransferable(Object dataObjects,
                                                   Object dataFlavor)

Creates an AdfObjectAdfTransferable representing multiple objects with the same AdfDataFlavor. The AdfDataFlavor is required.

Parameters:
dataObjects    
dataFlavor    
Return:
Object

createSingleObjectTransferable

public static AdfObjectTransferable createSingleObjectTransferable(Object data,
                                                                   Object dataFlavor)

Creates an AdfObjectAdfTransferable from an instance of the Object to transfer, and optionally an instance of the AdfDataFlavor for the Object. If the AdfDataFlavor is not provided, it will be calculated from the Object instance.

Parameters:
data  -  Data to transer
dataFlavor    
Return:
AdfObjectTransferable - The AdfObjectTransferable

getTransferData

public Object getTransferData(AdfDataFlavor dataFlavor)

Returns the array of data objects for this AdfDataFlavor, or null if no data for the specified AdfDataFlavor is available

Parameters:
dataFlavor  -  AdfDataFlavor to request data for
Return:
Object - The data for the flavor, if it exists in the transferable, or undefined if it does not.
See also:
isDataFlavorSupported(Object)
getTransferDataFlavors()
Overrides:
AdfTransferable.getTransferData(Object)

getTransferDataFlavors

public Object getTransferDataFlavors()

Returns the array of AdfDataFlavors for which this AdfTransferable has data. The returned array should not be mutated.

Return:
Object
See also:
isDataFlavorSupported(Object)
Overrides:
AdfTransferable.getTransferDataFlavors()

Init

protected Object Init(Array objectsForFlavors,
                      Array<AdfDataFlavor> dataFlavors,
                      Array baseObjects,
                      Array<Function> converters)

Initializes the instance. Subclasses of AdfObject must call their superclass' Init

Parameters:
objectsForFlavors    
dataFlavors    
baseObjects    
converters    
Return:
Object
Overrides:
AdfObject.Init()

isDataFlavorSupported

public Object isDataFlavorSupported(Object dataFlavor)

Returns true if the AdfTransferable contains data for the specified AdfDataFlavor

Parameters:
dataFlavor  -  The AdfDataFlavor to check the existence of
Return:
Object
Overrides:
AdfTransferable.isDataFlavorSupported(Object)

toDebugString

public Object toDebugString()

Return:
Object
Overrides:
AdfObject.toDebugString()

SUMMARY: FIELD | CONSTR | METHOD    DETAIL: FIELD | CONSTR | METHOD

 

Generated on 2011.10.24 21:45 UTC
Copyright (c) 1998, 2011, Oracle and/or its affiliates. All rights reserved.