MATLAB BUILDER JA 2 Guide de l'utilisateur Page 198

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 292
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 197
4 Using MWArra y Classes
Method Description
“numberOfDimensions” on
page 4-123
Returns the number o f dimensions of this
array.
“numberOfElements” on
page 4-123
Returns the total number of elements in this
array.
“numberOfFields” on page
4-123
Returns the number of fields in this array.
classID. This m ethod returns the MATLAB type of this array. The classID
method of MWStructArray overrides the classID method of class MWArray.
The prototype for the
classID method is
public MWClassID classID()
Input Parameters
None
Example Getting the Class ID of a Structure Array
Create an MWStructArray object and display the class ID:
int[] sdims = {1, 2};
String[] sfields = {"f1", "f2", "f3"};
MWStructArray S = new MWStructArray(sdims, sfields);
System.out.println("The class of S is " + S.classID());
When run, the example displays this output:
The class of S is struct
fieldNames. This method returns the field names in this array.
The prototype for the
fieldNames method is
4-122
Vue de la page 197
1 2 ... 193 194 195 196 197 198 199 200 201 202 203 ... 291 292

Commentaires sur ces manuels

Pas de commentaire