mirror of
https://github.com/openkmip/pykmip
synced 2025-12-15 07:43:26 +00:00
Adding server support for the GetAttributes operation
This change adds server support for the GetAttributes operation. The user can specify an object ID and an attribute list to get the values of the attributes listed from the specified object. The user can also omit either argument; the server will default to using the ID placeholder and all viable attributes respectively. Only a subset of the standard attributes are supported right now. New tests have been added to cover the new feature. Closes #185 Closes #211 Closes #218
This commit is contained in:
@@ -825,11 +825,10 @@ class TextString(Base):
|
||||
|
||||
def __validate(self):
|
||||
if self.value is not None:
|
||||
data_type = type(self.value)
|
||||
if data_type is not str:
|
||||
if not isinstance(self.value, six.string_types):
|
||||
msg = ErrorStrings.BAD_EXP_RECV
|
||||
raise TypeError(msg.format('TextString', 'value', str,
|
||||
data_type))
|
||||
type(self.value)))
|
||||
|
||||
def __repr__(self):
|
||||
return "{0}(value={1})".format(type(self).__name__, repr(self.value))
|
||||
|
||||
Reference in New Issue
Block a user