Examples of allKeys()


Examples of com.webobjects.foundation.NSMutableDictionary.allKeys()

            if( object != null ){
                this.checkRule(rule, attributeName, errorDict, object, GSVEngine.ON_DEMAND);
            }
           
            //if the error dict contains values, rules failed, so throw an exception
            if(errorDict.allKeys().count()>0){
                NSDictionary userInfo = new NSDictionary(errorDict, GSVEngine.ERROR_DICTIONARY_KEY);
                throw new NSValidation.ValidationException("Validity Exception", userInfo);
            }
           
        } else {
View Full Code Here

Examples of com.webobjects.foundation.NSMutableDictionary.allKeys()

    public void convertRuleDictionaryToKeyValue(){
        NSMutableDictionary dict = new NSMutableDictionary();
        dict = selectedRule.parameters();
        String k,v;
        KeyValue temp;
        for(int i = 0; i<dict.allKeys().count();i++){
            k = (String)dict.allKeys().objectAtIndex(i);
            v = (String)dict.objectForKey(k);
            temp  = new KeyValue(k,v);
            keyValueParameters.addObject(temp);
        }
View Full Code Here

Examples of com.webobjects.foundation.NSMutableDictionary.allKeys()

        NSMutableDictionary dict = new NSMutableDictionary();
        dict = selectedRule.parameters();
        String k,v;
        KeyValue temp;
        for(int i = 0; i<dict.allKeys().count();i++){
            k = (String)dict.allKeys().objectAtIndex(i);
            v = (String)dict.objectForKey(k);
            temp  = new KeyValue(k,v);
            keyValueParameters.addObject(temp);
        }
    }
View Full Code Here

Examples of com.webobjects.foundation.NSMutableDictionary.allKeys()

        try {
            NSMutableDictionary unknownApps = _unknownApplications;
            // Should make this configurable?
            NSTimestamp cutOffDate = new NSTimestamp(System.currentTimeMillis() - 45000);

            NSArray unknownAppKeys = unknownApps.allKeys();
            for (Enumeration e = unknownAppKeys.objectEnumerator(); e.hasMoreElements(); ) {
                String unknownAppKey = (String) e.nextElement();
                NSMutableDictionary appDict = (NSMutableDictionary) unknownApps.valueForKey(unknownAppKey);
                if (appDict != null) {
                    NSArray appDictKeys = appDict.allKeys();
View Full Code Here

Examples of com.webobjects.foundation.NSMutableDictionary.allKeys()

            NSArray unknownAppKeys = unknownApps.allKeys();
            for (Enumeration e = unknownAppKeys.objectEnumerator(); e.hasMoreElements(); ) {
                String unknownAppKey = (String) e.nextElement();
                NSMutableDictionary appDict = (NSMutableDictionary) unknownApps.valueForKey(unknownAppKey);
                if (appDict != null) {
                    NSArray appDictKeys = appDict.allKeys();
                    for (Enumeration e2 = appDictKeys.objectEnumerator(); e2.hasMoreElements(); ) {
                        String appDictKey = (String) e2.nextElement();
                        NSTimestamp lastLifebeat = (NSTimestamp) appDict.valueForKey(appDictKey);
                        if ( (lastLifebeat != null) && (lastLifebeat.before(cutOffDate)) ) {
                            appDict.removeObjectForKey(appDictKey);
View Full Code Here

Examples of javax.swing.ActionMap.allKeys()

  private void installAccelerators(JFrame furnitureFrame,
                                   final EditorController furnitureLibraryController) {
    JComponent furnitureLibraryView = (JComponent)furnitureLibraryController.getView();
    InputMap inputMap = furnitureLibraryView.getInputMap(JComponent.WHEN_IN_FOCUSED_WINDOW);
    ActionMap actionMap = furnitureLibraryView.getActionMap();
    for (Object key : actionMap.allKeys()) {
      if (key instanceof EditorView.ActionType) {
        inputMap.put((KeyStroke)actionMap.get(key).getValue(Action.ACCELERATOR_KEY), key);
      }
    }
  }
View Full Code Here

Examples of javax.swing.ActionMap.allKeys()

 
  public void test(TestHarness harness) {
          ActionMap map = new ActionMap();
          if (map.keys() != null)
            harness.fail("New ActionMap should return null for keys()");
          if (map.allKeys() != null)
            harness.fail ("New ActionMap should return null for allKeys()");
  }

}
View Full Code Here

Examples of javax.swing.ActionMap.allKeys()

    }

    public void testCreateActionMap() throws Exception {
        ui.installUI(fc);
        ActionMap map = ui.createActionMap();
        List<Object> allKeys = Arrays.asList(map.allKeys());
        assertEquals(3, allKeys.size());
        assertTrue(allKeys.contains("approveSelection"));
        assertEquals(ui.getApproveSelectionAction(), map.get("approveSelection"));
        assertTrue(allKeys.contains("cancelSelection"));
        assertEquals(ui.getCancelSelectionAction(), map.get("cancelSelection"));
View Full Code Here

Examples of javax.swing.ActionMap.allKeys()

        return false;
    }

    public Object[] getCommands() {
        ActionMap map = component.getActionMap();
        return map.allKeys();
    }

    public boolean hasCommand(Object command) {
        Object[] commands = getCommands();
        for (int i = 0; i < commands.length; i++) {
View Full Code Here

Examples of javax.swing.ActionMap.allKeys()

    }

    public void testCreateActionMap() throws Exception {
        ui.installUI(fc);
        ActionMap map = ui.createActionMap();
        List<Object> allKeys = Arrays.asList(map.allKeys());
        assertEquals(3, allKeys.size());
        assertTrue(allKeys.contains("approveSelection"));
        assertEquals(ui.getApproveSelectionAction(), map.get("approveSelection"));
        assertTrue(allKeys.contains("cancelSelection"));
        assertEquals(ui.getCancelSelectionAction(), map.get("cancelSelection"));
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.