Class ScriptAdapter
- java.lang.Object
- 
- com.inductiveautomation.ignition.common.project.resource.adapter.DefaultResourceTypeAdapter
- 
- com.inductiveautomation.ignition.common.project.resource.adapter.ScriptAdapter
 
 
- 
- All Implemented Interfaces:
- ResourceTypeAdapter
 
 public class ScriptAdapter extends DefaultResourceTypeAdapter 
- 
- 
Field Summary- 
Fields inherited from interface com.inductiveautomation.ignition.common.project.resource.adapter.ResourceTypeAdapterLEGACY_SINGLETON_ERRORED_NAME_PATTERN
 
- 
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description byte[]adaptData(byte[] data)Adapt the data from the original project resource, if necessary.java.nio.file.PathgetResourceDir(java.lang.String projectName)Returns the path to the resource directory for the resource being adapted.java.lang.StringgetResourceFileName()Get the name of the file that the adapted resource type should use to store its data on disk.- 
Methods inherited from class com.inductiveautomation.ignition.common.project.resource.adapter.DefaultResourceTypeAdaptergetNewResourceType
 - 
Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - 
Methods inherited from interface com.inductiveautomation.ignition.common.project.resource.adapter.ResourceTypeAdaptergetResourcePath
 
- 
 
- 
- 
- 
Method Detail- 
getResourceDirpublic java.nio.file.Path getResourceDir(java.lang.String projectName) Description copied from interface:ResourceTypeAdapterReturns the path to the resource directory for the resource being adapted.The default implementation is a simple Path with one component: the value of ResourceTypeAdapter.getNewResourceType().Custom implementations should may provide additional components but must begin with ResourceTypeAdapter.getNewResourceType().Most types won't care about projectName, but if this is called during a project import or upgrade from a legacy (<= 7.9),projectNamemay be important.- Parameters:
- projectName- the name of the project the resource being adapted belongs to.
 
 - 
getResourceFileNamepublic java.lang.String getResourceFileName() Description copied from interface:ResourceTypeAdapterGet the name of the file that the adapted resource type should use to store its data on disk.Defaults to ProjectResource.DEFAULT_DATA_KEY.- Returns:
- the name of the file that the adapted resource type should use to store its data on disk.
 
 - 
adaptDatapublic byte[] adaptData(byte[] data) Description copied from interface:ResourceTypeAdapterAdapt the data from the original project resource, if necessary.- Returns:
- the adapted data, if necessary.
 
 
- 
 
-