Example usage for java.util SortedMap size

List of usage examples for java.util SortedMap size

Introduction

In this page you can find the example usage for java.util SortedMap size.

Prototype

int size();

Source Link

Document

Returns the number of key-value mappings in this map.

Usage

From source file:net.sourceforge.msscodefactory.cfasterisk.v2_0.CFAstXMsgClient.CFAstXMsgClientVoicemailConfTable.java

public CFAstVoicemailConfBuff[] readDerivedByVMClusterIdx(CFAstAuthorization Authorization, long argClusterId) {
    final String S_ProcName = "readDerivedByVMClusterIdx";
    String rqst = CFAstXMsgSchemaMessageFormatter.formatRqstXmlPreamble() + "\n" + "\t"
            + CFAstXMsgVoicemailConfMessageFormatter.formatVoicemailConfRqstReadByVMClusterIdx("\n\t\t\t",
                    argClusterId)//from ww w . j  ava  2 s.  co m
            + "\n" + CFAstXMsgSchemaMessageFormatter.formatRqstXmlPostamble();
    String rspn = schema.sendReceive(Authorization, rqst);
    if ((rspn == null) || (rspn.length() <= 0)) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0, "rspn");
    }
    CFAstXMsgRspnHandler responseHandler = schema.getResponseHandler();
    responseHandler.parseStringContents(rspn);
    CFLibRuntimeException exceptionRaised = responseHandler.getExceptionRaised();
    if (exceptionRaised != null) {
        throw exceptionRaised;
    }
    Object sortedMapObj = responseHandler.getSortedMapOfObjects();
    if (sortedMapObj == null) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0,
                "responseHandler.getSortedMapOfObjects");
    }
    SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj> sortedMap = (SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj>) sortedMapObj;
    int sz = sortedMap.size();
    CFAstVoicemailConfBuff arr[] = new CFAstVoicemailConfBuff[sz];
    Iterator<ICFAstConfigurationFileObj> iter = sortedMap.values().iterator();
    ICFAstVoicemailConfObj cur;
    for (int idx = 0; idx < sz; idx++) {
        cur = (ICFAstVoicemailConfObj) iter.next();
        arr[idx] = cur.getVoicemailConfBuff();
    }
    return (arr);
}

From source file:net.sourceforge.msscodefactory.cfasterisk.v2_0.CFAstXMsgClient.CFAstXMsgClientAsteriskConfTable.java

public CFAstAsteriskConfBuff[] readDerivedByClusterIdx(CFAstAuthorization Authorization, long argClusterId) {
    final String S_ProcName = "readDerivedByClusterIdx";
    String rqst = CFAstXMsgSchemaMessageFormatter.formatRqstXmlPreamble() + "\n" + "\t"
            + CFAstXMsgAsteriskConfMessageFormatter.formatAsteriskConfRqstReadByClusterIdx("\n\t\t\t",
                    argClusterId)//from  w w w  .  java 2s  .c  o  m
            + "\n" + CFAstXMsgSchemaMessageFormatter.formatRqstXmlPostamble();
    String rspn = schema.sendReceive(Authorization, rqst);
    if ((rspn == null) || (rspn.length() <= 0)) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0, "rspn");
    }
    CFAstXMsgRspnHandler responseHandler = schema.getResponseHandler();
    responseHandler.parseStringContents(rspn);
    CFLibRuntimeException exceptionRaised = responseHandler.getExceptionRaised();
    if (exceptionRaised != null) {
        throw exceptionRaised;
    }
    Object sortedMapObj = responseHandler.getSortedMapOfObjects();
    if (sortedMapObj == null) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0,
                "responseHandler.getSortedMapOfObjects");
    }
    SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj> sortedMap = (SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj>) sortedMapObj;
    int sz = sortedMap.size();
    CFAstAsteriskConfBuff arr[] = new CFAstAsteriskConfBuff[sz];
    Iterator<ICFAstConfigurationFileObj> iter = sortedMap.values().iterator();
    ICFAstAsteriskConfObj cur;
    for (int idx = 0; idx < sz; idx++) {
        cur = (ICFAstAsteriskConfObj) iter.next();
        arr[idx] = cur.getAsteriskConfBuff();
    }
    return (arr);
}

From source file:net.sourceforge.msscodefactory.cfasterisk.v2_0.CFAstXMsgClient.CFAstXMsgClientExtConfigConfTable.java

public CFAstExtConfigConfBuff[] readDerivedByClusterIdx(CFAstAuthorization Authorization, long argClusterId) {
    final String S_ProcName = "readDerivedByClusterIdx";
    String rqst = CFAstXMsgSchemaMessageFormatter.formatRqstXmlPreamble() + "\n" + "\t"
            + CFAstXMsgExtConfigConfMessageFormatter.formatExtConfigConfRqstReadByClusterIdx("\n\t\t\t",
                    argClusterId)/*from www. java2s.c  o  m*/
            + "\n" + CFAstXMsgSchemaMessageFormatter.formatRqstXmlPostamble();
    String rspn = schema.sendReceive(Authorization, rqst);
    if ((rspn == null) || (rspn.length() <= 0)) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0, "rspn");
    }
    CFAstXMsgRspnHandler responseHandler = schema.getResponseHandler();
    responseHandler.parseStringContents(rspn);
    CFLibRuntimeException exceptionRaised = responseHandler.getExceptionRaised();
    if (exceptionRaised != null) {
        throw exceptionRaised;
    }
    Object sortedMapObj = responseHandler.getSortedMapOfObjects();
    if (sortedMapObj == null) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0,
                "responseHandler.getSortedMapOfObjects");
    }
    SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj> sortedMap = (SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj>) sortedMapObj;
    int sz = sortedMap.size();
    CFAstExtConfigConfBuff arr[] = new CFAstExtConfigConfBuff[sz];
    Iterator<ICFAstConfigurationFileObj> iter = sortedMap.values().iterator();
    ICFAstExtConfigConfObj cur;
    for (int idx = 0; idx < sz; idx++) {
        cur = (ICFAstExtConfigConfObj) iter.next();
        arr[idx] = cur.getExtConfigConfBuff();
    }
    return (arr);
}

From source file:net.sourceforge.msscodefactory.cfasterisk.v2_0.CFAstXMsgClient.CFAstXMsgClientVoicemailConfTable.java

public CFAstVoicemailConfBuff[] readDerivedByHostIdx(CFAstAuthorization Authorization, long argClusterId,
        long argHostNodeId) {
    final String S_ProcName = "readDerivedByHostIdx";
    String rqst = CFAstXMsgSchemaMessageFormatter.formatRqstXmlPreamble() + "\n" + "\t"
            + CFAstXMsgVoicemailConfMessageFormatter.formatVoicemailConfRqstReadByHostIdx("\n\t\t\t",
                    argClusterId, argHostNodeId)
            + "\n" + CFAstXMsgSchemaMessageFormatter.formatRqstXmlPostamble();
    String rspn = schema.sendReceive(Authorization, rqst);
    if ((rspn == null) || (rspn.length() <= 0)) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0, "rspn");
    }//from  w  w  w .  j  a  va2s.c  o m
    CFAstXMsgRspnHandler responseHandler = schema.getResponseHandler();
    responseHandler.parseStringContents(rspn);
    CFLibRuntimeException exceptionRaised = responseHandler.getExceptionRaised();
    if (exceptionRaised != null) {
        throw exceptionRaised;
    }
    Object sortedMapObj = responseHandler.getSortedMapOfObjects();
    if (sortedMapObj == null) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0,
                "responseHandler.getSortedMapOfObjects");
    }
    SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj> sortedMap = (SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj>) sortedMapObj;
    int sz = sortedMap.size();
    CFAstVoicemailConfBuff arr[] = new CFAstVoicemailConfBuff[sz];
    Iterator<ICFAstConfigurationFileObj> iter = sortedMap.values().iterator();
    ICFAstVoicemailConfObj cur;
    for (int idx = 0; idx < sz; idx++) {
        cur = (ICFAstVoicemailConfObj) iter.next();
        arr[idx] = cur.getVoicemailConfBuff();
    }
    return (arr);
}

From source file:net.sourceforge.msscodefactory.cfasterisk.v2_0.CFAstXMsgClient.CFAstXMsgClientAsteriskConfTable.java

public CFAstAsteriskConfBuff[] readDerivedByHostIdx(CFAstAuthorization Authorization, long argClusterId,
        long argHostNodeId) {
    final String S_ProcName = "readDerivedByHostIdx";
    String rqst = CFAstXMsgSchemaMessageFormatter.formatRqstXmlPreamble() + "\n" + "\t"
            + CFAstXMsgAsteriskConfMessageFormatter.formatAsteriskConfRqstReadByHostIdx("\n\t\t\t",
                    argClusterId, argHostNodeId)
            + "\n" + CFAstXMsgSchemaMessageFormatter.formatRqstXmlPostamble();
    String rspn = schema.sendReceive(Authorization, rqst);
    if ((rspn == null) || (rspn.length() <= 0)) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0, "rspn");
    }/*ww w  .  j a v a2  s.  co  m*/
    CFAstXMsgRspnHandler responseHandler = schema.getResponseHandler();
    responseHandler.parseStringContents(rspn);
    CFLibRuntimeException exceptionRaised = responseHandler.getExceptionRaised();
    if (exceptionRaised != null) {
        throw exceptionRaised;
    }
    Object sortedMapObj = responseHandler.getSortedMapOfObjects();
    if (sortedMapObj == null) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0,
                "responseHandler.getSortedMapOfObjects");
    }
    SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj> sortedMap = (SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj>) sortedMapObj;
    int sz = sortedMap.size();
    CFAstAsteriskConfBuff arr[] = new CFAstAsteriskConfBuff[sz];
    Iterator<ICFAstConfigurationFileObj> iter = sortedMap.values().iterator();
    ICFAstAsteriskConfObj cur;
    for (int idx = 0; idx < sz; idx++) {
        cur = (ICFAstAsteriskConfObj) iter.next();
        arr[idx] = cur.getAsteriskConfBuff();
    }
    return (arr);
}

From source file:net.sourceforge.msscodefactory.cfasterisk.v2_0.CFAstXMsgClient.CFAstXMsgClientAsteriskConfTable.java

public CFAstAsteriskConfBuff[] readDerivedByConfClusterIdx(CFAstAuthorization Authorization,
        long argClusterId) {
    final String S_ProcName = "readDerivedByConfClusterIdx";
    String rqst = CFAstXMsgSchemaMessageFormatter.formatRqstXmlPreamble() + "\n" + "\t"
            + CFAstXMsgAsteriskConfMessageFormatter.formatAsteriskConfRqstReadByConfClusterIdx("\n\t\t\t",
                    argClusterId)//www .  j av a  2s. c  o  m
            + "\n" + CFAstXMsgSchemaMessageFormatter.formatRqstXmlPostamble();
    String rspn = schema.sendReceive(Authorization, rqst);
    if ((rspn == null) || (rspn.length() <= 0)) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0, "rspn");
    }
    CFAstXMsgRspnHandler responseHandler = schema.getResponseHandler();
    responseHandler.parseStringContents(rspn);
    CFLibRuntimeException exceptionRaised = responseHandler.getExceptionRaised();
    if (exceptionRaised != null) {
        throw exceptionRaised;
    }
    Object sortedMapObj = responseHandler.getSortedMapOfObjects();
    if (sortedMapObj == null) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0,
                "responseHandler.getSortedMapOfObjects");
    }
    SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj> sortedMap = (SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj>) sortedMapObj;
    int sz = sortedMap.size();
    CFAstAsteriskConfBuff arr[] = new CFAstAsteriskConfBuff[sz];
    Iterator<ICFAstConfigurationFileObj> iter = sortedMap.values().iterator();
    ICFAstAsteriskConfObj cur;
    for (int idx = 0; idx < sz; idx++) {
        cur = (ICFAstAsteriskConfObj) iter.next();
        arr[idx] = cur.getAsteriskConfBuff();
    }
    return (arr);
}

From source file:net.sourceforge.msscodefactory.cfasterisk.v2_0.CFAstXMsgClient.CFAstXMsgClientExtConfigConfTable.java

public CFAstExtConfigConfBuff[] readDerivedByHostIdx(CFAstAuthorization Authorization, long argClusterId,
        long argHostNodeId) {
    final String S_ProcName = "readDerivedByHostIdx";
    String rqst = CFAstXMsgSchemaMessageFormatter.formatRqstXmlPreamble() + "\n" + "\t"
            + CFAstXMsgExtConfigConfMessageFormatter.formatExtConfigConfRqstReadByHostIdx("\n\t\t\t",
                    argClusterId, argHostNodeId)
            + "\n" + CFAstXMsgSchemaMessageFormatter.formatRqstXmlPostamble();
    String rspn = schema.sendReceive(Authorization, rqst);
    if ((rspn == null) || (rspn.length() <= 0)) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0, "rspn");
    }/* w ww.ja  v  a2  s. co  m*/
    CFAstXMsgRspnHandler responseHandler = schema.getResponseHandler();
    responseHandler.parseStringContents(rspn);
    CFLibRuntimeException exceptionRaised = responseHandler.getExceptionRaised();
    if (exceptionRaised != null) {
        throw exceptionRaised;
    }
    Object sortedMapObj = responseHandler.getSortedMapOfObjects();
    if (sortedMapObj == null) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0,
                "responseHandler.getSortedMapOfObjects");
    }
    SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj> sortedMap = (SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj>) sortedMapObj;
    int sz = sortedMap.size();
    CFAstExtConfigConfBuff arr[] = new CFAstExtConfigConfBuff[sz];
    Iterator<ICFAstConfigurationFileObj> iter = sortedMap.values().iterator();
    ICFAstExtConfigConfObj cur;
    for (int idx = 0; idx < sz; idx++) {
        cur = (ICFAstExtConfigConfObj) iter.next();
        arr[idx] = cur.getExtConfigConfBuff();
    }
    return (arr);
}

From source file:net.sourceforge.msscodefactory.cfasterisk.v2_0.CFAstXMsgClient.CFAstXMsgClientExtConfigConfTable.java

public CFAstExtConfigConfBuff[] readDerivedByExtCnfClusIdx(CFAstAuthorization Authorization,
        long argClusterId) {
    final String S_ProcName = "readDerivedByExtCnfClusIdx";
    String rqst = CFAstXMsgSchemaMessageFormatter.formatRqstXmlPreamble() + "\n" + "\t"
            + CFAstXMsgExtConfigConfMessageFormatter.formatExtConfigConfRqstReadByExtCnfClusIdx("\n\t\t\t",
                    argClusterId)//from   w  ww .j a va 2s  . c  o m
            + "\n" + CFAstXMsgSchemaMessageFormatter.formatRqstXmlPostamble();
    String rspn = schema.sendReceive(Authorization, rqst);
    if ((rspn == null) || (rspn.length() <= 0)) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0, "rspn");
    }
    CFAstXMsgRspnHandler responseHandler = schema.getResponseHandler();
    responseHandler.parseStringContents(rspn);
    CFLibRuntimeException exceptionRaised = responseHandler.getExceptionRaised();
    if (exceptionRaised != null) {
        throw exceptionRaised;
    }
    Object sortedMapObj = responseHandler.getSortedMapOfObjects();
    if (sortedMapObj == null) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0,
                "responseHandler.getSortedMapOfObjects");
    }
    SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj> sortedMap = (SortedMap<CFAstConfigurationFilePKey, ICFAstConfigurationFileObj>) sortedMapObj;
    int sz = sortedMap.size();
    CFAstExtConfigConfBuff arr[] = new CFAstExtConfigConfBuff[sz];
    Iterator<ICFAstConfigurationFileObj> iter = sortedMap.values().iterator();
    ICFAstExtConfigConfObj cur;
    for (int idx = 0; idx < sz; idx++) {
        cur = (ICFAstExtConfigConfObj) iter.next();
        arr[idx] = cur.getExtConfigConfBuff();
    }
    return (arr);
}

From source file:hudson.plugins.jobConfigHistory.FileHistoryDaoTest.java

private void testGetRevisions(SortedMap<String, HistoryDescr> result) {
    assertEquals(5, result.size());
    assertEquals("2012-11-21_11-29-12", result.firstKey());
    assertEquals("2012-11-21_11-42-05", result.lastKey());
    final HistoryDescr firstValue = result.get(result.firstKey());
    final HistoryDescr lastValue = result.get(result.lastKey());
    assertEquals("Created", firstValue.getOperation());
    assertEquals("anonymous", firstValue.getUserID());
    assertEquals("Changed", lastValue.getOperation());
}

From source file:net.sourceforge.msscodefactory.cfacc.v2_0.CFAccXMsgClient.CFAccXMsgClientSecGroupMemberTable.java

public CFAccSecGroupMemberBuff[] readAllDerived(CFAccAuthorization Authorization) {
    final String S_ProcName = "readAllDerived";
    String rqst = CFAccXMsgSchemaMessageFormatter.formatRqstXmlPreamble() + "\n" + "\t"
            + CFAccXMsgSecGroupMemberMessageFormatter.formatSecGroupMemberRqstReadAll("\n\t\t\t") + "\n"
            + CFAccXMsgSchemaMessageFormatter.formatRqstXmlPostamble();
    String rspn = schema.sendReceive(Authorization, rqst);
    if ((rspn == null) || (rspn.length() <= 0)) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0, "rspn");
    }//from   w w w. j  a  va2 s.c o  m
    CFAccXMsgRspnHandler responseHandler = schema.getResponseHandler();
    responseHandler.parseStringContents(rspn);
    CFLibRuntimeException exceptionRaised = responseHandler.getExceptionRaised();
    if (exceptionRaised != null) {
        throw exceptionRaised;
    }
    Object sortedMapObj = responseHandler.getSortedMapOfObjects();
    if (sortedMapObj == null) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0,
                "responseHandler.getSortedMapOfObjects");
    }
    SortedMap<CFAccSecGroupMemberPKey, ICFAccSecGroupMemberObj> sortedMap = (SortedMap<CFAccSecGroupMemberPKey, ICFAccSecGroupMemberObj>) sortedMapObj;
    int sz = sortedMap.size();
    CFAccSecGroupMemberBuff arr[] = new CFAccSecGroupMemberBuff[sz];
    Iterator<ICFAccSecGroupMemberObj> iter = sortedMap.values().iterator();
    ICFAccSecGroupMemberObj cur;
    for (int idx = 0; idx < sz; idx++) {
        cur = (ICFAccSecGroupMemberObj) iter.next();
        arr[idx] = cur.getSecGroupMemberBuff();
    }
    return (arr);
}