API java : TabularType


javax.management.openmbean
Class TabularType

java.lang.Object
  extended by javax.management.openmbean.OpenType
      extended by javax.management.openmbean.TabularType
All Implemented Interfaces:
Serializable

public class TabularType
extends OpenType
implements Serializable

The TabularType class is the open type class whose instances describe the types of TabularData values.

Since:
1.5
See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.management.openmbean.OpenType
ALLOWED_CLASSNAMES
 
Constructor Summary
TabularType(String typeName, String description, CompositeType rowType, String[] indexNames)
          Constructs a TabularType instance, checking for the validity of the given parameters.
 
Method Summary
 boolean equals(Object obj)
          Compares the specified obj parameter with this TabularType instance for equality.
 List getIndexNames()
          Returns, in the same order as was given to this instance's constructor, an unmodifiable List of the names of the items the values of which are used to uniquely index each row element of tabular data values described by this TabularType instance.
 CompositeType getRowType()
          Returns the type of the row elements of tabular data values described by this TabularType instance.
 int hashCode()
          Returns the hash code value for this TabularType instance.
 boolean isValue(Object obj)
          Tests whether obj is a value which could be described by this TabularType instance.
 String toString()
          Returns a string representation of this TabularType instance.
 
Methods inherited from class javax.management.openmbean.OpenType
getClassName, getDescription, getTypeName, isArray
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TabularType

public TabularType(String typeName,
                   String description,
                   CompositeType rowType,
                   String[] indexNames)
            throws OpenDataException
Constructs a TabularType instance, checking for the validity of the given parameters. The validity constraints are described below for each parameter.

The Java class name of tabular data values this tabular type represents (ie the class name returned by the getClassName method) is set to the string value returned by TabularData.class.getName().

Parameters:
typeName - The name given to the tabular type this instance represents; cannot be a null or empty string.
 
description - The human readable description of the tabular type this instance represents; cannot be a null or empty string.
 
rowType - The type of the row elements of tabular data values described by this tabular type instance; cannot be null.
 
indexNames - The names of the items the values of which are used to uniquely index each row element in the tabular data values described by this tabular type instance; cannot be null or empty. Each element should be an item name defined in rowType (no null or empty string allowed). It is important to note that the order of the item names in indexNames is used by the methods get and remove of class TabularData to match their array of values parameter to items.
 
Throws:
IllegalArgumentException - if rowType is null, or indexNames is a null or empty array, or an element in indexNames is a null or empty string, or typeName or description is a null or empty string.
 
OpenDataException - if an element's value of indexNames is not an item name defined in rowType.
Method Detail

getRowType

public CompositeType getRowType()
Returns the type of the row elements of tabular data values described by this TabularType instance.

Returns:
the type of each row.

getIndexNames

public List getIndexNames()

Returns, in the same order as was given to this instance's constructor, an unmodifiable List of the names of the items the values of which are used to uniquely index each row element of tabular data values described by this TabularType instance.

Returns:
a List of String representing the names of the index items.

isValue

public boolean isValue(Object obj)
Tests whether obj is a value which could be described by this TabularType instance.

If obj is null or is not an instance of javax.management.openmbean.TabularData, isValue returns false. If obj is an instance of javax.management.openmbean.TabularData, its tabular type is tested for equality with this tabular type instance, and isValue returns true if and only if equals returns true.
 

Specified by:
isValue in class OpenType
Parameters:
obj - the value whose open type is to be tested for equality with this TabularType instance.
Returns:
true if obj is a value for this tabular type, false otherwise.

equals

public boolean equals(Object obj)
Compares the specified obj parameter with this TabularType instance for equality.

Two TabularType instances are equal if and only if all of the following statements are true:

  • their type names are equal
  • their row types are equal
  • they use the same index names, in the same order

 

Specified by:
equals in class OpenType
Parameters:
obj - the object to be compared for equality with this TabularType instance; if obj is null, equals returns false.
Returns:
true if the specified object is equal to this TabularType instance.
See Also:
Object.hashCode(), Hashtable

hashCode

public int hashCode()
Returns the hash code value for this TabularType instance.

The hash code of a TabularType instance is the sum of the hash codes of all elements of information used in equals comparisons (ie: name, row type, index names). This ensures that t1.equals(t2) implies that t1.hashCode()==t2.hashCode() for any two TabularType instances t1 and t2, as required by the general contract of the method Object.hashCode().

As TabularType instances are immutable, the hash code for this instance is calculated once, on the first call to hashCode, and then the same value is returned for subsequent calls.

Specified by:
hashCode in class OpenType
Returns:
the hash code value for this TabularType instance
See Also:
Object.equals(java.lang.Object), Hashtable

toString

public String toString()
Returns a string representation of this TabularType instance.

The string representation consists of the name of this class (ie javax.management.openmbean.TabularType), the type name for this instance, the row type string representation of this instance, and the index names of this instance.

As TabularType instances are immutable, the string representation for this instance is calculated once, on the first call to toString, and then the same value is returned for subsequent calls.

Specified by:
toString in class OpenType
Returns:
a string representation of this TabularType instance

Ces informations proviennent du site de http://java.sun.com

Remarques

Contenu

Le contenu de cette page provient du site de Sun, et est généré depuis un cache sur l'infobrol après certains traitements automatisés. La présentation peut donc différer du document original, mais le contenu aussi. Vous pouvez utiliser ce bouton pour afficher la page originale du site de Sun :

Quels sont les motivations de cette démarche?

Maintenir les pages en cache sur différents sites peut offrir plus de disponibilité.

Chaque page est indexée dans la base de donnée, ce qui permet de retrouver facilement les informations, au moyen des sommaires, du moteur de recherche interne, etc.

Des facilités sont mises en place pour que les membres de l'infobrol puissent effectuer des traductions en français des différents documents. Ceci devrait permettre aux débutants en programmation Java de consulter les API en français s'ils maîtrisent moins bien la langue de Shakespeare. Dans le cas où une traduction a été soumise, elle est disponible au moyen d'un lien en bas de page. Si la traduction a été validée, la page s'affiche par défaut en français, et un lien en bas de page permet d'atteindre la version en anglais.

Le code sur l'infobrol est automatiquement coloré selon la syntaxe, et les différents mots clés sont transformés en liens pour accéder rapidement aux informations.

Vous avez la possibilité de partager vos expériences en proposant vos propres extraits de code en utilisant le bouton "ajouter un commentaire" en bas de page. Si vous visitez simplement l'infobrol, vous avez déjà accès à cette fonction, mais si vous étes membre du brol, vous pouvez en plus utiliser des boutons supplémentaires de mise en forme, dont la coloration automatique de vos extraits de codes.

Réseaux sociaux

Vous pouvez modifier vos préférences dans votre profil pour ne plus afficher les interactions avec les réseaux sociaux sur ces pages.

 

Nuage de mots clés

7 mots clés dont 0 définis manuellement (plus d'information...).

Avertissement

Cette page ne possède pas encore de mots clés manuels, ceci est donc un exemple automatique (les niveaux de pertinence sont fictifs, mais les liens sont valables). Pour tester le nuage avec une page qui contient des mots définis manuellement, vous pouvez cliquer ici.

Vous pouvez modifier vos préférences dans votre profil pour ne plus afficher le nuage de mots clés.

 

Astuce pour imprimer les couleurs des cellules de tableaux : http://www.gaudry.be/ast-rf-450.html
Aucun commentaire pour cette page

© Ce document issu de l′infobrol est enregistré sous le certificat Cyber PrInterDeposit Digital Numbertection. Enregistrement IDDN n° 5329-3149
Document créé le 01/09/06 02:40, dernière modification le Vendredi 17 Juin 2011, 12:12
Source du document imprimé : http://www.gaudry.be/java-api-rf-javax/management/openmbean/TabularType.html Document affiché 1 fois ce mois de Juin.
St.Gaudry©07.01.02
Outils (masquer)
||
Recherche (afficher)
Recherche :

Utilisateur (masquer)
Apparence (afficher)
Stats (afficher)
15832 documents
452 astuces.
549 niouzes.
3099 definitions.
447 membres.
8115 messages.

Document genere en :
0,48 seconde

Mises à jour :
Mises à jour du site
Citation (masquer)
Ne parlez jamais de vous, ni en bien, car on ne vous croirait pas, ni en mal car on ne vous croirait que trop.

Confucius
 
l'infobrol
Nous sommes le Samedi 02 Juin 2012, 00:29, toutes les heures sont au format GMT+1.00 Heure, heure d'été (+1)