ADC Home > Reference Library > Reference > Hardware & Drivers > I/O Kit Framework Reference
|
IOFireWireLibVectorCommandInterface |
Declared In: |
IOFireWireLib command object for grouping commands execution.
Read and Write commands can be attached in order to the vector command. When the vector command is submitted all the commands are sent to the kernel for execution. When all the commands in a vector command are complete the vector command's completion is called. The advantage over submitting and completeing each command simultaneously is that only one kernel transition will be used for submission and one for completion, regardless of the number of commands in the vector.
Adds a command to the vector command.
Sets the number of commands this vector can hold.
Returns the command at a given index.
Returns the number of commands currently in this vector.
Get the flags currently set for this command.
Returns the index of the specified command.
Get the reference constant for this command.
Inserts a command at a given index. Commands at and after this index will be moved to their next sequential index.
Checks if the vector command is currently executing.
Removes all commands from the vector.
Removes a command to the vector command.
Removes the command at a give index. Commands at and afte this index will be moved to their previous sequential index.
Set the callback routine for this command.
Set flags governing this command's execution.
Set flags governing this command's execution.
Set the reference constant for this command.
Submit this command object to FireWire for execution.
Submit this command object to FireWire for execution.
Submit this command object to FireWire for execution.
AddCommand |
Adds a command to the vector command.
void ( *AddCommand)( IOFireWireLibVectorCommandRef self, IOFireWireLibCommandRef command);
self
A reference to the vector command object
command
A reference to the command to add
An IOReturn result code
EnsureCapacity |
Sets the number of commands this vector can hold.
IOReturn ( *EnsureCapacity)( IOFireWireLibVectorCommandRef self, UInt32 capacity);
self
A reference to the vector command object
capacity
The number of commands this vector command should expect to hold
An IOReturn result code
The vector can grow dynamically, but for performance reasons developers may want the storage preallocated for a certain number of commmands
GetCommandAtIndex |
Returns the command at a given index.
IOFireWireLibCommandRef ( *GetCommandAtIndex)( IOFireWireLibVectorCommandRef self, UInt32 index);
self
A reference to the vector command object
index
The index to return a command from
The IOFireWireLibCommandRef at the specified index on return
Returns kIOReturnBadArgument if the index is out of bounds.
GetCommandCount |
Returns the number of commands currently in this vector.
UInt32 ( *GetCommandCount)( IOFireWireLibVectorCommandRef self);
self
A reference to the vector command object
UInt32 The number of commands in this vector
GetFlags |
Get the flags currently set for this command.
UInt32 ( *GetFlags)( IOFireWireLibVectorCommandRef self);
self
A reference to the vector command object
The flags set in SetFlags
GetIndexOfCommand |
Returns the index of the specified command.
UInt32 ( *GetIndexOfCommand)( IOFireWireLibVectorCommandRef self, IOFireWireLibCommandRef command);
self
A reference to the vector command object
command
The command in question
The index of the specified command
Returns kIOReturnNotFound if the command does not exist in this vector.
GetRefCon |
Get the reference constant for this command.
void * ( *GetRefCon)( IOFireWireLibVectorCommandRef self);
self
A reference to the vector command object
The reference contant set in SetRefCon
InsertCommandAtIndex |
Inserts a command at a given index. Commands at and after this index will be moved to their next sequential index.
void ( *InsertCommandAtIndex)( IOFireWireLibVectorCommandRef self, IOFireWireLibCommandRef command, UInt32 index);
self
A reference to the vector command object
command
A reference to the command to be inserted
index
The index to insert the command at.
IsExecuting |
Checks if the vector command is currently executing.
Boolean ( *IsExecuting)( IOFireWireLibVectorCommandRef self);
self
A reference to the vector command object
True if the command is executing, false otherwise
RemoveAllCommands |
Removes all commands from the vector.
void ( *RemoveAllCommands)( IOFireWireLibVectorCommandRef self);
self
A reference to the vector command object
RemoveCommand |
Removes a command to the vector command.
void ( *RemoveCommand)( IOFireWireLibVectorCommandRef self, IOFireWireLibCommandRef command);
self
A reference to the vector command object
command
A reference to the command to be removed
An IOReturn result code
RemoveCommandAtIndex |
Removes the command at a give index. Commands at and afte this index will be moved to their previous sequential index.
void ( *RemoveCommandAtIndex)( IOFireWireLibVectorCommandRef self, UInt32 index);
self
A reference to the vector command object
command
The command in question
outIndex
Will be set to the index of the specified command.
Returns kIOReturnBadArgument if the index is out of bounds.
SetCallback |
Set the callback routine for this command.
void ( *SetCallback)( IOFireWireLibVectorCommandRef self, IOFireWireLibCommandCallback inCallback);
self
A reference to the vector command object
inCallback
A callback function to be called upon command completion.
void
SetFlags |
Set flags governing this command's execution.
void ( *SetFlags)( IOFireWireLibVectorCommandRef self, UInt32 inFlags);
self
A reference to the vector command object
inFlags
A UInt32 with bits set corresponding to the flags that should be set
for this command object. The following values may be used:
void
SetRefCon(IOFireWireLibVectorCommandRef, UInt32) |
Set flags governing this command's execution.
void ( *SetFlags)( IOFireWireLibVectorCommandRef self, UInt32 inFlags);
self
A reference to the vector command object
inFlags
A UInt32 with bits set corresponding to the flags that should be set
for this command object. The following values may be used:
void
SetRefCon(IOFireWireLibVectorCommandRef, void *) |
Set the reference constant for this command.
void ( *SetRefCon)( IOFireWireLibVectorCommandRef self, void *refCon);
self
A reference to the vector command object
refCon
A reference constant for 3rd party use.
void
Submit(IOFireWireLibVectorCommandRef) |
Submit this command object to FireWire for execution.
IOReturn ( *Submit)( IOFireWireLibVectorCommandRef self);
self
A reference to the vector command object
An IOReturn result code
Submit(IOFireWireLibVectorCommandRef, void *, IOFireWireLibCommandCallback) |
Submit this command object to FireWire for execution.
IOReturn ( *SubmitWithRefconAndCallback)( IOFireWireLibVectorCommandRef self, void *refCon, IOFireWireLibCommandCallback inCallback);
self
A reference to the vector command object
refCon
A reference constant for 3rd party use. This is the same refcon set with SetRefCon and retreived with GetRefCon.
inCallback
A callback function to be called upon command completion.
An IOReturn result code
A convienence method to set the callback and refcon and then submit.
SubmitWithRefconAndCallback |
Submit this command object to FireWire for execution.
IOReturn ( *SubmitWithRefconAndCallback)( IOFireWireLibVectorCommandRef self, void *refCon, IOFireWireLibCommandCallback inCallback);
self
A reference to the vector command object
refCon
A reference constant for 3rd party use. This is the same refcon set with SetRefCon and retreived with GetRefCon.
inCallback
A callback function to be called upon command completion.
An IOReturn result code
A convienence method to set the callback and refcon and then submit.
|
Last Updated: 2009-02-23