Added optional active/inactive text properties to Binary Output object.

This commit is contained in:
skarg
2008-10-13 19:00:25 +00:00
parent 075edab107
commit 1dad528da8
+12
View File
@@ -64,6 +64,8 @@ static const int Binary_Output_Properties_Required[] = {
static const int Binary_Output_Properties_Optional[] = {
PROP_DESCRIPTION,
PROP_ACTIVE_TEXT,
PROP_INACTIVE_TEXT,
-1
};
@@ -305,6 +307,16 @@ int Binary_Output_Encode_Property_APDU(
present_value = RELINQUISH_DEFAULT;
apdu_len = encode_application_enumerated(&apdu[0], present_value);
break;
case PROP_ACTIVE_TEXT:
characterstring_init_ansi(&char_string,"on" );
apdu_len =
encode_application_character_string(&apdu[0], &char_string);
break;
case PROP_INACTIVE_TEXT:
characterstring_init_ansi(&char_string,"off" );
apdu_len =
encode_application_character_string(&apdu[0], &char_string);
break;
default:
*error_class = ERROR_CLASS_PROPERTY;
*error_code = ERROR_CODE_UNKNOWN_PROPERTY;