#include <IAssignment.h>
This class is used to model the assignment of stories and images.
- See Also
- IAssignedDocument
- IAssignmentMgr
The assignment compatibility.
| Enumerator |
|---|
| kAssignmentCS3Compatibility | Compatible with CS3: Assignment file is INCA format and can only contain INCX and INCD stories. |
| kAssignmentCS4Compatibility | Optimized for CS4: Assignment file is ICMA format and can only have ICML stories. |
| kUnassignedCompatibility | Unassigned: Assignment does not export and can contain all assigned story formats. |
The assignment preview export options.
| Enumerator |
|---|
| kAssignmentExportFrames | Export only wireframes for unassigned stories, no content or images |
| kAssignmentExportSpreads | Export only the spreads which have assigned stories on them |
| kAssignmentExportAll | Export the entire publication |
Adds a story to the assignment. This must be called from a command.
- Parameters
Deletes an assigned story from the database. This must be called from a command.
- Parameters
| story | - The assigned story to delete. Do not hold onto this story, as it will be deleted and uncallable after this completes. |
| virtual UID IAssignment::GetColor | ( | | ) | const |
| pure virtual |
The color to use when showing assigned frame edges.
- Returns
- - The UID of the color object, which should be an IInCopyUIColor object.
Determines and returns the compatibility for this assignment. This is read-only and, except for Unassigned, is computed based on the assignment file type info ID where kAssignmentFileTypeInfoID is kAssignmentCS3Compatibility and kAssignmentMarkupFileTypeInfoID is kAssignmentCS4Compatibility.
- Returns
- - The compatibility enumeration.
| virtual bool16 IAssignment::GetDirty | ( | | ) | |
| pure virtual |
Whether the assignment needs to be written or not. Dirty assignments have changed since last updated.
- Returns
- - True if not saved.
The assignment preview export level for this assignment.
- Returns
- - The export level enumeration.
| virtual const PMString& IAssignment::GetFile | ( | | ) | |
| pure virtual |
Returns the path of the assignment file itself.
- Returns
- - A reference to the assignment's PMString file path.
| virtual bool16 IAssignment::GetIncludeLinkedFilesWhenPackage | ( | | ) | const |
| pure virtual |
The assignment option for including linked files or not when packaging.
- Returns
- bool16 kTrue if should include, otherwise kFalse.
| virtual const PMString& IAssignment::GetName | ( | | ) | const |
| pure virtual |
Returns the name of the assignment.
- Returns
- A reference to the assignment's PMString name
| virtual UIDList IAssignment::GetStories | ( | | ) | const |
| pure virtual |
The list of stories in this assignment. You can ask this list for a const iterator.
- Returns
- - A const reference to the list, which can supply a const_iterator.
| virtual const URI& IAssignment::GetURI | ( | | ) | |
| pure virtual |
Returns the URI of the assignment itself.
- Returns
- - A reference to the assignment's URI.
| virtual const PMString& IAssignment::GetUser | ( | | ) | const |
| pure virtual |
The name that this assignment is assigned to. Currently only displayed in the panel, not used.
- Returns
- - A reference to the assigned name.
Reorders the story list. This must be called from a command.
- Parameters
| story | - The assigned story to move. |
| beforeStory | - The assigned story to place this before. Pass nil for the end of the list. |
Process a command to move a story within the assigned story list.
- Parameters
| story | - The story to move. |
| beforeStory | - The story to move before, or nil for the end. |
- Returns
- - Any errors that may have occurred.
Removes a story from the assignment and unregisters it from its page items. This will unreference the story, so keep a reference if you want to use it. This must be called from a command.
- Parameters
| story | - The story to remove. |
| virtual ErrorCode IAssignment::RemoveStoryCmd | ( | IAssignedStory * | story | ) | |
| pure virtual |
Processes a command which removes an assigned story from the assignment.
- Parameters
| story | - The assigned story to remove. |
- Returns
- - Any errors that may have occurred.
| virtual void IAssignment::SetColor | ( | UID | color | ) | |
| pure virtual |
Set the color for an assignment to use when showing assigned frame edges.
- Parameters
| color | - The UID of the IInCopyUIColor object. |
| virtual void IAssignment::SetDirty | ( | bool16 | dirty | ) | |
| pure virtual |
Set whether or not this assignment should be saved.
- Parameters
| dirty | - Pass true in to make sure this assignment requests to be saved, or false if you want to mark this assignment as up to date. |
Set the assignment preview export level.
- Parameters
| options | - The enumeration desired. |
| virtual void IAssignment::SetFile | ( | const PMString & | file | ) | |
| pure virtual |
Changes the file the assignment writes to.
- Parameters
| file | - A new file path in the current platform encoding. |
| virtual void IAssignment::SetIncludeLinkedFilesWhenPackage | ( | bool16 | includeFlag | ) | |
| pure virtual |
Set the assignment option for including linked files or not when packaging.
- Parameters
| includeFlag | pass kTrue to include linked files, otherwise kFalse. |
| virtual void IAssignment::SetName | ( | const PMString & | name | ) | |
| pure virtual |
Sets the name of the assignment.
- Parameters
| name | - A PMString containing the new name. |
Process a command to set the various properties of an assignment.
- Parameters
| name | - A pointer to a new name, or nil to not change the name. |
| file | - A pointer to a new file path, or nil to not change the file path. |
| user | - A pointer to a new user name, or nil to not change the user name. |
| color | - A pointer to the new color, or nil to not change the color. |
| options | - A pointer to the new export options, or nil to not change the export options. |
| dirty | - A pointer to the new dirty flag, or nil to not change the dirty state |
| includeLinkFilesPackaging | - A pointer to the new option for including linked files when packaging. |
| uri | - A pointer to the new uri, or nil to base the uri on the file if provided or to not change the uri. (typically allowing the other changes to dirty the assignment). |
- Returns
- - Any errors that may have occured.
| virtual void IAssignment::SetURI | ( | const URI & | uri | ) | |
| pure virtual |
Changes the URI the assignment writes to.
- Parameters
| virtual void IAssignment::SetUser | ( | const PMString & | user | ) | |
| pure virtual |
Set the name of the assigned user for this assignment. Currently only displayed in the panel, not used.
- Parameters
| user | - A PMString containing the new user name. |