sav.z
Class BaseExtension

java.lang.Object
  extended bysav.z.VariableExtension
      extended bysav.z.BaseExtension

public class BaseExtension
extends VariableExtension

Methods extension to the Base class for advanced developers.

Since:
8.0
See Also:
Base.be()

Method Summary
 java.lang.String[] attrArray2(java.lang.String obj, java.lang.String attribute, int nh)
          Retrieves nh+2 size array of attribute values for all the zclass members.
 java.lang.String attrType(java.lang.String zclass, java.lang.String attribute)
          Returns attribute type of zclass.
 int attrTypeN(java.lang.String zclass, java.lang.String attribute)
          Returns the type notation corresponding to zclass attribute.
 int[] attrTypeN(java.lang.String zclass, java.lang.String[] attributes)
          Returns the type notations corresponding to zclass attributes.
 java.lang.String[] attrTypes(java.lang.String zclass, java.lang.String[] attributes)
          Returns the types corresponding zclass attributes.
 java.lang.String backN(java.lang.String zclass, java.lang.String value, int notation)
          Returns a back value before the value in zclass Zigzag class.
 java.lang.String[] classAttrArray(java.lang.String zclass, java.lang.String attribute)
          Retrieves array of attribute values for all the zclass members.
 java.lang.String[] classAttrArray(java.lang.String zclass, java.lang.String attribute, boolean self)
          Retrieves array of attribute values for all the zclass members including the zclass object if the self is true.
 java.util.Vector denotations(java.lang.String zclass)
          Obtains the Vector values that have DENOTATION notation category inside zclass.
 java.util.Vector designations(java.lang.String zclass)
          Obtains the Vector values that have DESIGNATION notation category inside of zclass.
 java.lang.String firstN(java.lang.String zclass, int notation)
          Returns first value of the notation type inside zclass.
 boolean hasNextN(java.lang.String zclass, java.lang.String value, int notation)
          Tests whether are value of the notation after value type inside specified zclass Zigzag class.
 boolean hasNotation(java.lang.String zclass, int notation)
          Tests whether value of the notation type is inside specified zclass Zigzag class.
 java.lang.String lastN(java.lang.String zclass, int notation)
          Returns last value of the notation type inside the zclass Zigzag class.
 java.lang.String[] nextArrayN(java.lang.String zclass, java.lang.String value, int size, int notation)
          Returns next size array values of the notation type after value inside zclass.
 java.lang.String nextN(java.lang.String zclass, java.lang.String value, int notation)
          Returns next value of the notation type after value inside zclass.
 java.util.Vector qsymbols(java.lang.String zclass)
          Returns the Vector of first symbols the quoted values begin with, in zclass Zigzag class.
 void setAttrType(java.lang.String zclass, java.lang.String attribute, java.lang.String type)
          Sets up the type to the attribute of zclass.
 int size(java.lang.String zclass, int de)
          Determines the size of the values that have de as weither DESIGNATION or DENOTATION inside zclass.
 java.util.Vector symbols(java.lang.String zclass, java.lang.String before)
          Returns the Vector of symbols after before the quoted values begin with, inside zclass.
 
Methods inherited from class sav.z.VariableExtension
backN, denotations, designations, firstN, hasNextN, hasNotation, lastN, nextArrayN, nextN, qsymbols, size, symbols
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

hasNotation

public boolean hasNotation(java.lang.String zclass,
                           int notation)
                    throws java.io.IOException
Tests whether value of the notation type is inside specified zclass Zigzag class. The notation may be PN.SPECIFIC, PN.SIGN, PN.QUOTE, PN.NUMBER, PN.CAPITAL, PN.NATURAL, PN.RUSSIAN_C, PN.RUSSIAN_N.

Throws:
java.io.IOException
See Also:
ClassNavigation.has(String, String)

firstN

public java.lang.String firstN(java.lang.String zclass,
                               int notation)
                        throws java.io.IOException
Returns first value of the notation type inside zclass.

Throws:
java.io.IOException
See Also:
ClassNavigation.first(String), hasNotation(String, int)

hasNextN

public boolean hasNextN(java.lang.String zclass,
                        java.lang.String value,
                        int notation)
                 throws java.io.IOException
Tests whether are value of the notation after value type inside specified zclass Zigzag class.

Throws:
java.io.IOException
See Also:
firstN(String, int), hasNotation(String, int)

nextN

public java.lang.String nextN(java.lang.String zclass,
                              java.lang.String value,
                              int notation)
                       throws java.io.IOException
Returns next value of the notation type after value inside zclass.

Throws:
java.io.IOException
See Also:
ClassNavigation.next(String, String), firstN(String, int), hasNotation(String, int)

nextArrayN

public java.lang.String[] nextArrayN(java.lang.String zclass,
                                     java.lang.String value,
                                     int size,
                                     int notation)
                              throws java.io.IOException
Returns next size array values of the notation type after value inside zclass.

Throws:
java.io.IOException
See Also:
ClassNavigation.nextArray(String, String, int), firstN(String, int), hasNotation(String, int)

lastN

public java.lang.String lastN(java.lang.String zclass,
                              int notation)
                       throws java.io.IOException
Returns last value of the notation type inside the zclass Zigzag class.

Throws:
java.io.IOException
See Also:
ClassNavigation.last(String), backN(String, String, int), firstN(String, int), hasNotation(String, int)

backN

public java.lang.String backN(java.lang.String zclass,
                              java.lang.String value,
                              int notation)
                       throws java.io.IOException
Returns a back value before the value in zclass Zigzag class.

Throws:
java.io.IOException
See Also:
ClassNavigation.back(String, String), lastN(String, int), hasNotation(String, int)

qsymbols

public java.util.Vector qsymbols(java.lang.String zclass)
                          throws java.io.IOException
Returns the Vector of first symbols the quoted values begin with, in zclass Zigzag class.

Throws:
java.io.IOException
See Also:
symbols(String, String)

symbols

public java.util.Vector symbols(java.lang.String zclass,
                                java.lang.String before)
                         throws java.io.IOException
Returns the Vector of symbols after before the quoted values begin with, inside zclass.

Throws:
java.io.IOException
See Also:
qsymbols(String)

size

public int size(java.lang.String zclass,
                int de)
         throws java.io.IOException
Determines the size of the values that have de as weither DESIGNATION or DENOTATION inside zclass.

Throws:
java.io.IOException
See Also:
denotations(String), designations(String)

denotations

public java.util.Vector denotations(java.lang.String zclass)
                             throws java.io.IOException
Obtains the Vector values that have DENOTATION notation category inside zclass.

Throws:
java.io.IOException
See Also:
VariableExtension.size(int), designations(String)

designations

public java.util.Vector designations(java.lang.String zclass)
                              throws java.io.IOException
Obtains the Vector values that have DESIGNATION notation category inside of zclass.

Throws:
java.io.IOException
See Also:
VariableExtension.size(int), denotations(String)

classAttrArray

public java.lang.String[] classAttrArray(java.lang.String zclass,
                                         java.lang.String attribute)
                                  throws java.io.IOException
Retrieves array of attribute values for all the zclass members.

Throws:
java.io.IOException
See Also:
Base.attrArray(String, String)

classAttrArray

public java.lang.String[] classAttrArray(java.lang.String zclass,
                                         java.lang.String attribute,
                                         boolean self)
                                  throws java.io.IOException
Retrieves array of attribute values for all the zclass members including the zclass object if the self is true.

Throws:
java.io.IOException
See Also:
classAttrArray(String, String)

attrArray2

public java.lang.String[] attrArray2(java.lang.String obj,
                                     java.lang.String attribute,
                                     int nh)
                              throws java.io.IOException
Retrieves nh+2 size array of attribute values for all the zclass members. The array size may be less than nh+2. System seeks to give out first nh (or less), one middle and one last values.

Throws:
java.io.IOException
See Also:
Base.attrArray(String, String)

attrType

public java.lang.String attrType(java.lang.String zclass,
                                 java.lang.String attribute)
                          throws java.io.IOException
Returns attribute type of zclass. For various applications the attribute types may be different. For example, the Smans server, based on this Sav Zigzag DBMS, has type symbol sequence consisting of 4 symbols, like NRQO, N--O, CRQ-. Each symbol in each position has a specific meaning. Only the '-' in any place signifies an uncertainty. Following is description of the type symbols for each of 4 positions.
 1 attribute value notation: N Number PN.NUMBER, 
                             C Char PN.QUOTE,
 2 necessary attribute: R Required,
 3 used in query attribute: Q Quering,
 4 output attribute: O Output.
 

Throws:
java.io.IOException
See Also:
setAttrType(String, String, String)

setAttrType

public void setAttrType(java.lang.String zclass,
                        java.lang.String attribute,
                        java.lang.String type)
                 throws java.io.IOException
Sets up the type to the attribute of zclass. Really, the type definition for Zigzag data is not required as for the XML data. Neverheless, type control is very useful for the the software application during the input or output data. A developer can set up herself types (or attribute constraint) via arbitrary symbol sequence.

Throws:
java.io.IOException
See Also:
attrType(String, String), attrTypes(String, String[])

attrTypes

public java.lang.String[] attrTypes(java.lang.String zclass,
                                    java.lang.String[] attributes)
                             throws java.io.IOException
Returns the types corresponding zclass attributes.

Throws:
java.io.IOException
See Also:
Base.header(String), attrType(String, String)

attrTypeN

public int attrTypeN(java.lang.String zclass,
                     java.lang.String attribute)
              throws java.io.IOException
Returns the type notation corresponding to zclass attribute. This method tests only the N first symbol of type name (or symbol sequence that signifies type). If first symbol is N, the returned value is PN.NUMBER, in other case PN.QUOTE. The source code of this very simple method has following view:
 public int attrN(String zclass, String attribute) throws IOException {
   String s = attrType(zclass, attribute);
   if (s.startsWith("N"))
     return PN.NUMBER;
   else
     return PN.QUOTE;
 }//attrN
 

Throws:
java.io.IOException
See Also:
attrType(String, String), firstN(String, int)

attrTypeN

public int[] attrTypeN(java.lang.String zclass,
                       java.lang.String[] attributes)
                throws java.io.IOException
Returns the type notations corresponding to zclass attributes. This method tests only the N first symbol of type name (or symbol sequence that signifies type). If first symbol is N, the returned array value is PN.NUMBER, in other case PN.QUOTE.

Throws:
java.io.IOException
See Also:
attrType(String, String), attrTypeN(String, String)