Package com.webobjects.foundation

Examples of com.webobjects.foundation.NSDictionary.valueForKey()


            MInstance anInstance = (MInstance)anInstArray.objectAtIndex(i);
            NSDictionary aStatsDict = anInstance.statistics();

            if (aStatsDict != null) {
                try {
                    String aValue = (String) aStatsDict.valueForKey("transactions");
                    aTotalTrans = aTotalTrans + Integer.parseInt(aValue);
                } catch (Throwable ex) {
                    // do nothing
                }
            }
View Full Code Here


            MInstance anInstance = (MInstance)anInstArray.objectAtIndex(i);
            NSDictionary aStatsDict = anInstance.statistics();

            if (aStatsDict != null) {
                try {
                    String aValue = (String) aStatsDict.valueForKey("activeSessions");
                    aTotalActiveSessions = aTotalActiveSessions + Integer.parseInt(aValue);
                } catch (Throwable ex) {
                    // do nothing
                }
            }
View Full Code Here

        for (MInstance anInstance : instances) {
          if (anInstance.isRunning_M()){
              NSDictionary statistics = anInstance.statistics();
              if (statistics != null) {
                  try {
                      String aValue = (String) statistics.valueForKey(statisticsKey);
                      sum = sum + Integer.parseInt(aValue);
                  } catch (Throwable ex) {
                      // do nothing
                  }
              } 
View Full Code Here

            MInstance anInstance = (MInstance)anInstArray.objectAtIndex(i);
            NSDictionary aStatsDict = anInstance.statistics();

            if (aStatsDict != null) {
                try {
                    String aValue = (String)aStatsDict.valueForKey("transactions");
                    Integer aTrans = Integer.valueOf(aValue);

                    if (aTrans.intValue() > 0) {
                        aValue = (String)aStatsDict.valueForKey("avgTransactionTime");
                        Float aTime = Float.valueOf(aValue);
View Full Code Here

                try {
                    String aValue = (String)aStatsDict.valueForKey("transactions");
                    Integer aTrans = Integer.valueOf(aValue);

                    if (aTrans.intValue() > 0) {
                        aValue = (String)aStatsDict.valueForKey("avgTransactionTime");
                        Float aTime = Float.valueOf(aValue);
                        aTotalTime = aTotalTime + (aTrans.intValue() * aTime.floatValue());
                        aTotalTrans = aTotalTrans + (aTrans.intValue());
                    }
                } catch (Throwable ex) {
View Full Code Here

            MInstance anInstance = (MInstance)anInstArray.objectAtIndex(i);
            NSDictionary aStatsDict = anInstance.statistics();

            if (aStatsDict != null) {
                try {
                    String aValue = (String)aStatsDict.valueForKey("transactions");
                    Integer aTrans = Integer.valueOf(aValue);

                     if (aTrans.intValue() > 0) {
                         String idleString = (String)aStatsDict.valueForKey("averageIdlePeriod");
                         Float aTime = Float.valueOf(idleString);
View Full Code Here

                try {
                    String aValue = (String)aStatsDict.valueForKey("transactions");
                    Integer aTrans = Integer.valueOf(aValue);

                     if (aTrans.intValue() > 0) {
                         String idleString = (String)aStatsDict.valueForKey("averageIdlePeriod");
                         Float aTime = Float.valueOf(idleString);
                         aTotalTime = aTotalTime + (aTrans.intValue() * aTime.floatValue());
                         aTotalTrans = aTotalTrans + (aTrans.intValue());
                     }
                } catch (Throwable ex) {
View Full Code Here

            String aStartDate = "";
            float anInstRate = (float)0.0;
            Integer aTrans;

            if (aStatsDict != null) {
                aStartDate = (String)aStatsDict.valueForKey("startedAt");
                try {
                    aTrans = Integer.valueOf((String) aStatsDict.valueForKey("transactions"));
                } catch (Throwable ex) {
                    aTrans = null;
                }
View Full Code Here

            Integer aTrans;

            if (aStatsDict != null) {
                aStartDate = (String)aStatsDict.valueForKey("startedAt");
                try {
                    aTrans = Integer.valueOf((String) aStatsDict.valueForKey("transactions"));
                } catch (Throwable ex) {
                    aTrans = null;
                }
                if (aTrans != null && (aTrans.intValue() > 0)) {
                    NSTimestamp aDate;
View Full Code Here

    @Override
    public void addCreateClauseForAttribute(EOAttribute attribute) {
      NSDictionary userInfo = attribute.userInfo();
      Object defaultValue = null;
      if (userInfo != null) {
          defaultValue = userInfo.valueForKey("er.extensions.eoattribute.default"); // deprecated key
          if (defaultValue == null) {
            defaultValue = userInfo.valueForKey("default");
          }
      }
      String allowsNullClauseForConstraint = allowsNullClauseForConstraint(shouldAllowNull(attribute));
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.