public AtTag ( byte tag, ApplicationTag defaultTag ) : bool | ||
tag | byte | The tag number to check for, or 255 for an application tag |
defaultTag | ApplicationTag | The application tag to check for |
Результат | bool |
public bool AtTag(byte tag, ApplicationTag defaultTag)
{
bool ret = false;
bool hasHeader = _peekHeader();
if(hasHeader)
{
bool context = (tag != 255);
byte tagNumber = (context ? tag : (byte)defaultTag);
return (_isContext == context && _tagNumber == tagNumber);
}
return ret;
}