ASCOM.Internal.Extensions
Extension methods relating to .
The recognized ASCOM device classes.
This list is specifically intended to support the Template Project Wizard
and contains a list of the device types for which the Wizard can expand
a project template.
Determines whether the specified file is device specific.
The file.
true if it is device specific; otherwise, false.
A file is considered 'device specific' if it meets the following criteria:
-
The filename contains at least two dots ('.');
-
The first dot-delimited segment of the filename matches one of the
recognized interface types contained in
tring extension methods
Defines a lookup table of bit masks, for a fast method of determining
a mask for any given bit position.
N.B. It might just be quicker to raise to a power of two,
the compiler might be smart enough to optimize that.
Returns a boolean value corresponding to the value at the specified bit position.
The register, an unsigned integer, containing bit values.
The bit position to be tested, where bit 0 is the least significant bit.
A boolean value corresponding to the bit at the specified bit position.
Returns a boolean value corresponding to the value at the specified bit position.
The register, an integer, containing bit values.
The bit position to be tested, where bit 0 is the least significant bit.
A boolean value corresponding to the bit at the specified bit position.
String extension methods.
Internal use only. Driver and application developers should not rely on this class,
because the interface and method signatures may change at any time.
Returns the specified number of characters from the head of a string.
The source string.
The number of characters to be returned, must not be greater than the length of the string.
The specified number of characters from the head of the source string, as a new string.
Thrown if the requested number of characters exceeds the string length.
Returns the specified number of characters from the tail of a string.
The source string.
The number of characters to be returned, must not be greater than the length of the string.
The specified number of characters from the tail of the source string, as a new string.
Thrown if the requested number of characters exceeds the string length.
Cleans (that is, removes all unwanted characters) from the string.
The source string.
A list of the allowed characters. All other characters will be removed.
A new string with all of the unwanted characters deleted.
Remove the head of the string, leaving the tail.
The source string.
Number of characters to remove from the head.
A new string containing the old string with characters removed from the head.
Remove the tail of the string, leaving the head.
The source string.
Number of characters to remove from the tail.
A new string containing the old string with characters removed from the tail.