Class AsciiCommandExtensions
- Namespace
- TechnologySolutions.Rfid.AsciiOperations
- Assembly
- TechnologySolutions.Rfid.Operations.dll
Extension methods to generate TechnologySolutions.Rfid.AsciiProtocol.Commands from TagAccessFilterFields and TagFilterFields
public static class AsciiCommandExtensions- Inheritance
- 
      
      AsciiCommandExtensions
- Inherited Members
Methods
ApplyAntennaBounds<TAsciiCommand>(TAsciiCommand, IAntennaParameterBounds)
Updates the command's minimum and maximum output power limits to the bounds specified
public static TAsciiCommand ApplyAntennaBounds<TAsciiCommand>(this TAsciiCommand command, IAntennaParameterBounds bounds) where TAsciiCommand : IAntennaParameterCommandBoundsParameters
- commandTAsciiCommand
- The command on which to set the limits 
- boundsIAntennaParameterBounds
- The limits to apply 
Returns
- TAsciiCommand
- The command with the limits set to bounds 
Type Parameters
- TAsciiCommand
- A command with IAntennaParameterCommandBounds 
ApplyAntennaBounds<TAsciiCommand>(TAsciiCommand, IReaderConfiguration)
Updates the command's minimum and maximum output power limits to the bounds specified
public static TAsciiCommand ApplyAntennaBounds<TAsciiCommand>(this TAsciiCommand command, IReaderConfiguration bounds) where TAsciiCommand : IAntennaParameterCommandBoundsParameters
- commandTAsciiCommand
- The command on which to set the limits 
- boundsIReaderConfiguration
- The limits to apply 
Returns
- TAsciiCommand
- The command with the limits set to bounds 
Type Parameters
- TAsciiCommand
- A command with IAntennaParameterCommandBounds 
ApplyAntenna<TAsciiCommand>(TAsciiCommand, TagFilter)
Sets OutputPower from the value OutputPower
public static TAsciiCommand ApplyAntenna<TAsciiCommand>(this TAsciiCommand antenna, TagFilter filter) where TAsciiCommand : IAntennaParametersParameters
- antennaTAsciiCommand
- The command to update 
- filterTagFilter
- The filter that specifies the output power 
Returns
- TAsciiCommand
- The command with the updated output power 
Type Parameters
- TAsciiCommand
- The command with an OutputPower parameter 
ApplyQuery<TAsciiCommand>(TAsciiCommand, TagFilter)
Configures the IQueryParameters of the ASCII command based on the filter
public static TAsciiCommand ApplyQuery<TAsciiCommand>(this TAsciiCommand query, TagFilter filter) where TAsciiCommand : IQueryParametersParameters
- queryTAsciiCommand
- The command to configure 
- filterTagFilter
- The filter to apply 
Returns
- TAsciiCommand
- The command configured with the specified filter 
Type Parameters
- TAsciiCommand
- A command that supports IQueryParameters 
ApplyReport<TAsciiCommand>(TAsciiCommand, TagFields)
Configures the fields of the TransponderData that are populated based on the ITransponderParameters. Configures the ITransponderParameters of the ASCII Command based on the fields specified
public static TAsciiCommand ApplyReport<TAsciiCommand>(this TAsciiCommand include, TagFields fields) where TAsciiCommand : ITransponderParametersParameters
- includeTAsciiCommand
- The command to configure 
- fieldsTagFields
- The fields to specify 
Returns
- TAsciiCommand
- The command configured to return the fields specified 
Type Parameters
- TAsciiCommand
- A command that supports ITransponderParameters 
ApplySelect(FindTagCommand, TagFilter)
Applies the Bank, Mask, Length and Offset form filter to the find tag command
public static FindTagCommand ApplySelect(this FindTagCommand select, TagFilter filter)Parameters
- selectFindTagCommand
- The command to update 
- filterTagFilter
- The filter to apply 
Returns
- FindTagCommand
- The command updated with the filter 
Remarks
The rest of the filter is configured for us by the command so we just take the fields we need to add
ApplySelect<TAsciiCommand>(TAsciiCommand, TagFilter)
Configures the ISelectParameters of the ASCII command based on the filter
public static TAsciiCommand ApplySelect<TAsciiCommand>(this TAsciiCommand select, TagFilter filter) where TAsciiCommand : ISelectParametersParameters
- selectTAsciiCommand
- The command to configure 
- filterTagFilter
- The filter to apply 
Returns
- TAsciiCommand
- The command configured for the specified filter 
Type Parameters
- TAsciiCommand
- A command that supports ISelectParameters to configure 
ToDatabank(MemoryBank)
Converts a MemoryBank to a Databank
public static Databank ToDatabank(this MemoryBank memory)Parameters
- memoryMemoryBank
- The value to convert 
Returns
- Databank
- The equivalent value 
ToInventory(TagFilterFields, IReaderConfiguration)
Returns the equivalent InventoryCommand for specified TagFilterFields
public static InventoryCommand ToInventory(this TagFilterFields filterFields, IReaderConfiguration bounds = null)Parameters
- filterFieldsTagFilterFields
- The transponders to return and the fields to report 
- boundsIReaderConfiguration
- Sets the output power bounds to the permitted range before setting the output power 
Returns
- InventoryCommand
- The inventory command equivalent to filterFields 
ToPasswordHex(int)
Converts a 32 bit password value to the ASCII Protocol equivalent
public static string ToPasswordHex(this int password)Parameters
- passwordint
- The value to convert 
Returns
- string
- The converted value 
ToSelectTarget(int)
Converts a Session to a SelectTarget
public static SelectTarget ToSelectTarget(this int session)Parameters
- sessionint
- The session flag to convert 
Returns
- SelectTarget
- The select target 
ToTagAccessCommand(TagAccessFilterFields, IReaderConfiguration)
Returns the equivalent ASCII 2 Protocol Tag Access command for the access specification
public static TranspondersCommandBase ToTagAccessCommand(this TagAccessFilterFields access, IReaderConfiguration bounds = null)Parameters
- accessTagAccessFilterFields
- The access command, transponder filter and fields to report 
- boundsIReaderConfiguration
- The output power bounds to use 
Returns
- TranspondersCommandBase
- The equivalent ASCII 2 Protocol tag access command for access 
ToTriState(TagFields, bool)
Returns a TriState based on flagsValue > 0
public static TriState? ToTriState(this TagFields flagsValue, bool defaultValue)