-
- All Superinterfaces:
- DynAnyOperations, DynValueCommonOperations
- All Known Subinterfaces:
- DynValue
- All Known Implementing Classes:
- _DynValueStub
public interface DynValueOperations extends DynValueCommonOperations
DynValue objects support the manipulation of IDL non-boxed value types. The DynValue interface can represent both null and non-null value types. For a DynValue representing a non-null value type, the DynValue's components comprise the public and private members of the value type, including those inherited from concrete base value types, in the order of definition. A DynValue representing a null value type has no components and a current position of -1.Warning: Indiscriminantly changing the contents of private value type members can cause the value type implementation to break by violating internal constraints. Access to private members is provided to support such activities as ORB bridging and debugging and should not be used to arbitrarily violate the encapsulation of the value type.
-
-
Method Summary
Methods Modifier and Type Method and Description TCKind
current_member_kind()
Returns the TCKind associated with the member at the current position.String
current_member_name()
Returns the name of the member at the current position.NameDynAnyPair[]
get_members_as_dyn_any()
Returns a sequence of NameDynAnyPairs describing the name and the value of each member in the value type.NameValuePair[]
get_members()
Returns a sequence of NameValuePairs describing the name and the value of each member in the value type.void
set_members_as_dyn_any(NameDynAnyPair[] value)
Initializes the value type's members from a sequence of NameDynAnyPairs.void
set_members(NameValuePair[] value)
Initializes the value type's members from a sequence of NameValuePairs.-
Methods inherited from interface org.omg.DynamicAny.DynValueCommonOperations
is_null, set_to_null, set_to_value
-
Methods inherited from interface org.omg.DynamicAny.DynAnyOperations
assign, component_count, copy, current_component, destroy, equal, from_any, get_any, get_boolean, get_char, get_double, get_dyn_any, get_float, get_long, get_longlong, get_octet, get_reference, get_short, get_string, get_typecode, get_ulong, get_ulonglong, get_ushort, get_val, get_wchar, get_wstring, insert_any, insert_boolean, insert_char, insert_double, insert_dyn_any, insert_float, insert_long, insert_longlong, insert_octet, insert_reference, insert_short, insert_string, insert_typecode, insert_ulong, insert_ulonglong, insert_ushort, insert_val, insert_wchar, insert_wstring, next, rewind, seek, to_any, type
-
-
-
-
Method Detail
-
current_member_name
String current_member_name() throws TypeMismatch, InvalidValue
Returns the name of the member at the current position. This operation may return an empty string since the TypeCode of the value being manipulated may not contain the names of members.- Throws:
TypeMismatch
- if the DynValue represents a null value type.InvalidValue
- if the current position does not indicate a member
-
current_member_kind
TCKind current_member_kind() throws TypeMismatch, InvalidValue
Returns the TCKind associated with the member at the current position.- Throws:
TypeMismatch
- if the DynValue represents a null value type.InvalidValue
- if the current position does not indicate a member
-
get_members
NameValuePair[] get_members() throws InvalidValue
Returns a sequence of NameValuePairs describing the name and the value of each member in the value type. The sequence contains members in the same order as the declaration order of members as indicated by the DynValue's TypeCode. The current position is not affected. The member names in the returned sequence will be empty strings if the DynValue's TypeCode does not contain member names.- Throws:
InvalidValue
- if this object represents a null value type
-
set_members
void set_members(NameValuePair[] value) throws TypeMismatch, InvalidValue
Initializes the value type's members from a sequence of NameValuePairs. The operation sets the current position to zero if the passed sequences has non-zero length. Otherwise, if an empty sequence is passed, the current position is set to -1. A null value type can be initialized to a non-null value type using this method.Members must appear in the NameValuePairs in the order in which they appear in the IDL specification of the value type as indicated by the DynValue's TypeCode or they must be empty strings. The operation makes no attempt to assign member values based on member names.
- Throws:
TypeMismatch
- if the member names supplied in the passed sequence do not match the corresponding member name in the DynValue's TypeCode and they are not empty stringsInvalidValue
- if the passed sequence has a number of elements that disagrees with the number of members as indicated by the DynValue's TypeCode
-
get_members_as_dyn_any
NameDynAnyPair[] get_members_as_dyn_any() throws InvalidValue
Returns a sequence of NameDynAnyPairs describing the name and the value of each member in the value type. The sequence contains members in the same order as the declaration order of members as indicated by the DynValue's TypeCode. The current position is not affected. The member names in the returned sequence will be empty strings if the DynValue's TypeCode does not contain member names.- Throws:
InvalidValue
- if this object represents a null value type
-
set_members_as_dyn_any
void set_members_as_dyn_any(NameDynAnyPair[] value) throws TypeMismatch, InvalidValue
Initializes the value type's members from a sequence of NameDynAnyPairs. The operation sets the current position to zero if the passed sequences has non-zero length. Otherwise, if an empty sequence is passed, the current position is set to -1. A null value type can be initialized to a non-null value type using this method.Members must appear in the NameDynAnyPairs in the order in which they appear in the IDL specification of the value type as indicated by the DynValue's TypeCode or they must be empty strings. The operation makes no attempt to assign member values based on member names.
- Throws:
TypeMismatch
- if the member names supplied in the passed sequence do not match the corresponding member name in the DynValue's TypeCode and they are not empty stringsInvalidValue
- if the passed sequence has a number of elements that disagrees with the number of members as indicated by the DynValue's TypeCode
-
-
Traduction non disponible
Les API Java ne sont pas encore traduites en français sur l'infobrol. Seule la version anglaise est disponible pour l'instant.
Version en cache
06/11/2024 00:31:10 Cette version de la page est en cache (à la date du 06/11/2024 00:31:10) afin d'accélérer le traitement. Vous pouvez activer le mode utilisateur dans le menu en haut pour afficher la dernère version de la page.Document créé le 30/08/2006, dernière modification le 04/03/2020
Source du document imprimé : https://www.gaudry.be/java-api-rf-org/omg/DynamicAny/DynValueOperations.html
L'infobrol est un site personnel dont le contenu n'engage que moi. Le texte est mis à disposition sous licence CreativeCommons(BY-NC-SA). Plus d'info sur les conditions d'utilisation et sur l'auteur.
Références
Ces références et liens indiquent des documents consultés lors de la rédaction de cette page, ou qui peuvent apporter un complément d'information, mais les auteurs de ces sources ne peuvent être tenus responsables du contenu de cette page.
L'auteur de ce site est seul responsable de la manière dont sont présentés ici les différents concepts, et des libertés qui sont prises avec les ouvrages de référence. N'oubliez pas que vous devez croiser les informations de sources multiples afin de diminuer les risques d'erreurs.