com.ibm.ftt.resources.zos.zosphysical
Interface ZOSResource

All Superinterfaces:
org.eclipse.core.runtime.IAdaptable, IPhysicalResource
All Known Subinterfaces:
ZOSDataSet, ZOSDataSetMember, ZOSGenerationDataGroup, ZOSPartitionedDataSet, ZOSSequentialDataSet, ZOSVsamDataSet

public interface ZOSResource
extends IPhysicalResource

An abstract interface for an object that represents a resource in a z/OS system.


Field Summary
static String COPY_RIGHT
           
 
Method Summary
 void copy(IPhysicalResource targetFolder, String name, boolean force, boolean lock, org.eclipse.core.runtime.IProgressMonitor monitor)
          Copies this resource into the target container.
 String getCharset()
           
 com.ibm.ftt.resources.zos.mapping.MVSFileMapping getMVSFileMapping()
          Returns a new MVS file mapping object representing the mapping attributes actually applied to this resource.
 com.ibm.ftt.resources.zos.mapping.MVSFileMapping getMVSFileMappingOverride()
          Returns a copy of MVS file mapping object representing the mapping override for this specific resource.
 String getName()
          Returns the name of this resource.
 ZOSResourceIdentifier getResourceIdentifier()
          Returns a z/OS resource identifier.
 void setMVSFileMappingOverride(com.ibm.ftt.resources.zos.mapping.MVSFileMapping mapping)
          Sets a mapping override to this resource.
 
Methods inherited from interface com.ibm.ftt.resources.core.physical.IPhysicalResource
delete, deleteOverriddenPropertiesInCategory, deleteOverride, exists, getCurrentPropertyGroup, getFullPath, getModificationStamp, getModificationStamp, getOverriddenProperties, getParent, getPersistentProperty, getResourcePublisher, getSessionProperty, refresh, rename, setCurrentPropertyGroup, setOverride, setPersistentProperty, setSessionProperty
 

Field Detail

COPY_RIGHT

static final String COPY_RIGHT
See Also:
Constant Field Values
Method Detail

copy

void copy(IPhysicalResource targetFolder,
          String name,
          boolean force,
          boolean lock,
          org.eclipse.core.runtime.IProgressMonitor monitor)
          throws OperationFailedException
Copies this resource into the target container. A new resource of the same type will be created.

Currently the copy method is implemented only for ZOSDataSetMember with a target container of type ZOSPartitionedDataSet and ZOSSequentialDataSet with a target container of type ZOSCatalog.

Parameters:
targetFolder - target container to create the new resource in
name - name of the new resource that will be created. The name should be unique in the target container
force - currently not used
lock - true if the target container should be locked before copying
monitor - a progress monitor, or null if progress reporting is not desired
Throws:
OperationFailedException

getName

String getName()
Description copied from interface: IPhysicalResource
Returns the name of this resource.

Specified by:
getName in interface IPhysicalResource
Returns:
the name of the resource

getResourceIdentifier

ZOSResourceIdentifier getResourceIdentifier()
Returns a z/OS resource identifier.

Returns:
an appropriate identifier that refers to the current resource object

getMVSFileMappingOverride

com.ibm.ftt.resources.zos.mapping.MVSFileMapping getMVSFileMappingOverride()
Returns a copy of MVS file mapping object representing the mapping override for this specific resource.

The returned mapping contains value for overridden attributes, or null for attributes to be inherited. Changing the mapping object itself does not affects this resource. To apply any changes, it must be set by calling setMVSFileMappingOverride(MVSFileMapping).

Returns:
the mapping object associated with this resource. If this resource has no such mapping override, creates a new blank mapping object and returns it
See Also:
setMVSFileMappingOverride(MVSFileMapping), getMVSFileMapping()

getMVSFileMapping

com.ibm.ftt.resources.zos.mapping.MVSFileMapping getMVSFileMapping()
Returns a new MVS file mapping object representing the mapping attributes actually applied to this resource.

The returned mapping contains values determined by merging all the inherited values and overridden values defined through z/OS File System Mapping view and resource property pages. Changing the mapping object itself does not affects this resource. If any mapping attributes need to be changed for this specific resource, mapping override can be set by calling setMVSFileMappingOverride(MVSFileMapping).

Returns:
the mapping object that contains values actually applied to this resource
See Also:
getMVSFileMappingOverride(), setMVSFileMappingOverride(MVSFileMapping)

setMVSFileMappingOverride

void setMVSFileMappingOverride(com.ibm.ftt.resources.zos.mapping.MVSFileMapping mapping)
Sets a mapping override to this resource.

The mapping can contain values to override inherited attributes, or null for attributes to be inherited.

When this method is called, UI refresh may occur according to the setting, for example, file extension change, etc.

Parameters:
mapping - the mapping object to set. If null is specified, mapping override will be cleaned from this resource
See Also:
getMVSFileMappingOverride(), getMVSFileMapping()

getCharset

String getCharset()
                  throws OperationFailedException
Returns:
The name of the char set that should be used to interpret the contents of this resource.
Throws:
OperationFailedException
See Also:
IPhysicalFile.getContents()