/// <summary> /// Creates the action descriptor suite. /// </summary> /// <param name="aete">The AETE scripting information.</param> /// <param name="descriptorHandle">The descriptor handle.</param> /// <param name="scriptingData">The scripting data.</param> /// <param name="zstringSuite">The ASZString suite instance.</param> /// <exception cref="ArgumentNullException"><paramref name="zstringSuite"/> is null.</exception> /// <exception cref="ObjectDisposedException">The class has been disposed.</exception> public void CreateDescriptorSuite(PluginAETE aete, IntPtr descriptorHandle, Dictionary <uint, AETEValue> scriptingData, IASZStringSuite zstringSuite) { if (zstringSuite == null) { throw new ArgumentNullException(nameof(zstringSuite)); } if (disposed) { throw new ObjectDisposedException(nameof(ActionSuiteProvider)); } if (!DescriptorSuiteCreated) { if (!ReferenceSuiteCreated) { CreateReferenceSuite(); } if (!ListSuiteCreated) { CreateListSuite(zstringSuite); } actionDescriptorSuite = new ActionDescriptorSuite(aete, actionListSuite, actionReferenceSuite, zstringSuite); actionListSuite.ActionDescriptorSuite = actionDescriptorSuite; if (scriptingData != null) { actionDescriptorSuite.SetScriptingData(descriptorHandle, scriptingData); } } }
/// <summary> /// Initializes a new instance of the <see cref="PluginData" /> class. /// </summary> /// <param name="fileName">The file name of the filter.</param> /// <param name="entryPoint">The entry point of the filter.</param> /// <param name="category">The category of the filter.</param> /// <param name="title">The title of the filter.</param> /// <param name="filterInfo">The filter information that describes how images with transparency should be processed.</param> /// <param name="aete">The scripting data of the filter.</param> /// <param name="enableInfo">The information describing the conditions that the filter requires to execute.</param> /// <param name="supportedModes">The bit field describing the image modes supported by the filter.</param> /// <param name="hasAboutBox">Indicates if the filter has an about box.</param> /// <exception cref="ArgumentNullException"><paramref name="fileName"/> is null.</exception> internal PluginData(string fileName, string entryPoint, string category, string title, FilterCaseInfo[] filterInfo, PluginAETE aete, string enableInfo, ushort?supportedModes, bool hasAboutBox) { if (fileName == null) { throw new ArgumentNullException(nameof(fileName)); } this.fileName = fileName; this.entryPoint = entryPoint; this.category = category; this.title = title; this.filterInfo = filterInfo; this.aete = aete; this.enableInfo = enableInfo; this.supportedModes = supportedModes; moduleEntryPoints = null; this.hasAboutBox = hasAboutBox; }
/// <summary> /// Initializes a new instance of the <see cref="ActionDescriptorSuite"/> class. /// </summary> /// <param name="aete">The AETE scripting information.</param> /// <param name="actionListSuite">The action list suite instance.</param> /// <param name="actionReferenceSuite">The action reference suite instance.</param> /// <param name="zstringSuite">The ASZString suite instance.</param> /// <exception cref="ArgumentNullException"> /// <paramref name="actionListSuite"/> is null. /// or /// <paramref name="actionReferenceSuite"/> is null. /// or /// <paramref name="zstringSuite"/> is null. /// </exception> public ActionDescriptorSuite(PluginAETE aete, IActionListSuite actionListSuite, IActionReferenceSuite actionReferenceSuite, IASZStringSuite zstringSuite) { if (actionListSuite == null) { throw new ArgumentNullException(nameof(actionListSuite)); } if (actionReferenceSuite == null) { throw new ArgumentNullException(nameof(actionReferenceSuite)); } if (zstringSuite == null) { throw new ArgumentNullException(nameof(zstringSuite)); } make = new ActionDescriptorMake(Make); free = new ActionDescriptorFree(Free); handleToDescriptor = new ActionDescriptorHandleToDescriptor(HandleToDescriptor); asHandle = new ActionDescriptorAsHandle(AsHandle); getType = new ActionDescriptorGetType(GetType); getKey = new ActionDescriptorGetKey(GetKey); hasKey = new ActionDescriptorHasKey(HasKey); getCount = new ActionDescriptorGetCount(GetCount); isEqual = new ActionDescriptorIsEqual(IsEqual); erase = new ActionDescriptorErase(Erase); clear = new ActionDescriptorClear(Clear); hasKeys = new ActionDescriptorHasKeys(HasKeys); putInteger = new ActionDescriptorPutInteger(PutInteger); putFloat = new ActionDescriptorPutFloat(PutFloat); putUnitFloat = new ActionDescriptorPutUnitFloat(PutUnitFloat); putString = new ActionDescriptorPutString(PutString); putBoolean = new ActionDescriptorPutBoolean(PutBoolean); putList = new ActionDescriptorPutList(PutList); putObject = new ActionDescriptorPutObject(PutObject); putGlobalObject = new ActionDescriptorPutGlobalObject(PutGlobalObject); putEnumerated = new ActionDescriptorPutEnumerated(PutEnumerated); putReference = new ActionDescriptorPutReference(PutReference); putClass = new ActionDescriptorPutClass(PutClass); putGlobalClass = new ActionDescriptorPutGlobalClass(PutGlobalClass); putAlias = new ActionDescriptorPutAlias(PutAlias); putIntegers = new ActionDescriptorPutIntegers(PutIntegers); putZString = new ActionDescriptorPutZString(PutZString); putData = new ActionDescriptorPutData(PutData); getInteger = new ActionDescriptorGetInteger(GetInteger); getFloat = new ActionDescriptorGetFloat(GetFloat); getUnitFloat = new ActionDescriptorGetUnitFloat(GetUnitFloat); getStringLength = new ActionDescriptorGetStringLength(GetStringLength); getString = new ActionDescriptorGetString(GetString); getBoolean = new ActionDescriptorGetBoolean(GetBoolean); getList = new ActionDescriptorGetList(GetList); getObject = new ActionDescriptorGetObject(GetObject); getGlobalObject = new ActionDescriptorGetGlobalObject(GetGlobalObject); getEnumerated = new ActionDescriptorGetEnumerated(GetEnumerated); getReference = new ActionDescriptorGetReference(GetReference); getClass = new ActionDescriptorGetClass(GetClass); getGlobalClass = new ActionDescriptorGetGlobalClass(GetGlobalClass); getAlias = new ActionDescriptorGetAlias(GetAlias); getIntegers = new ActionDescriptorGetIntegers(GetIntegers); getZString = new ActionDescriptorGetZString(GetZString); getDataLength = new ActionDescriptorGetDataLength(GetDataLength); getData = new ActionDescriptorGetData(GetData); this.aete = aete; this.actionListSuite = actionListSuite; this.actionReferenceSuite = actionReferenceSuite; this.zstringSuite = zstringSuite; actionDescriptors = new Dictionary <IntPtr, ScriptingParameters>(IntPtrEqualityComparer.Instance); descriptorHandles = new Dictionary <IntPtr, ScriptingParameters>(IntPtrEqualityComparer.Instance); actionDescriptorsIndex = 0; HandleSuite.Instance.SuiteHandleDisposed += SuiteHandleDisposed; disposed = false; }