test_class.file: smart-zeppelin/zeppelin-interpreter/src/test/java/org/apache/zeppelin/interpreter/InterpreterHookRegistryTest.java
test_class.identifier: InterpreterHookRegistryTest
test_case.body: @Test(expected = IllegalArgumentException.class)
    public void testValidEventCode() {
      InterpreterHookRegistry registry = new InterpreterHookRegistry("intpId");
      
      // Test that only valid event codes ("pre_exec", "post_exec") are accepted
      registry.register("foo", "bar", "baz", "whatever");
    }
test_case.class_method_signature: InterpreterHookRegistryTest.testValidEventCode()
test_case.full_signature: @Test(expected = IllegalArgumentException.class) public void testValidEventCode()
test_case.identifier: testValidEventCode
test_case.invocations: register
test_case.modifiers: @Test(expected = IllegalArgumentException.class) public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testValidEventCode()
focal_class.declarator: GLOBAL_KEY = "_GLOBAL_"
focal_class.modifier: public static final
focal_class.original_string: public static final String GLOBAL_KEY = "_GLOBAL_";
focal_class.type: String
focal_class.var_name: GLOBAL_KEY
focal_class.declarator: interpreterId
focal_class.modifier: private
focal_class.original_string: private String interpreterId;
focal_class.type: String
focal_class.var_name: interpreterId
focal_class.declarator: registry = new HashMap<>()
focal_class.modifier: private
focal_class.original_string: private Map<String, Map<String, Map<String, String>>> registry = new HashMap<>();
focal_class.type: Map<String, Map<String, Map<String, String>>>
focal_class.var_name: registry
focal_class.file: smart-zeppelin/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/InterpreterHookRegistry.java
focal_class.identifier: InterpreterHookRegistry
focal_class.class_method_signature: InterpreterHookRegistry.InterpreterHookRegistry(final String interpreterId)
focal_class.full_signature: public  InterpreterHookRegistry(final String interpreterId)
focal_class.identifier: InterpreterHookRegistry
focal_class.modifiers: public
focal_class.parameters: (final String interpreterId)
focal_class.signature:  InterpreterHookRegistry(final String interpreterId)
focal_class.class_method_signature: InterpreterHookRegistry.getInterpreterId()
focal_class.full_signature: public String getInterpreterId()
focal_class.identifier: getInterpreterId
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String getInterpreterId()
focal_class.class_method_signature: InterpreterHookRegistry.addNote(String noteId)
focal_class.full_signature: public void addNote(String noteId)
focal_class.identifier: addNote
focal_class.modifiers: public
focal_class.parameters: (String noteId)
focal_class.return: void
focal_class.signature: void addNote(String noteId)
focal_class.class_method_signature: InterpreterHookRegistry.addRepl(String noteId, String className)
focal_class.full_signature: public void addRepl(String noteId, String className)
focal_class.identifier: addRepl
focal_class.modifiers: public
focal_class.parameters: (String noteId, String className)
focal_class.return: void
focal_class.signature: void addRepl(String noteId, String className)
focal_class.class_method_signature: InterpreterHookRegistry.register(String noteId, String className,
                         String event, String cmd)
focal_class.full_signature: public void register(String noteId, String className,
                         String event, String cmd)
focal_class.identifier: register
focal_class.modifiers: public
focal_class.parameters: (String noteId, String className,
                         String event, String cmd)
focal_class.return: void
focal_class.signature: void register(String noteId, String className,
                         String event, String cmd)
focal_class.class_method_signature: InterpreterHookRegistry.unregister(String noteId, String className, String event)
focal_class.full_signature: public void unregister(String noteId, String className, String event)
focal_class.identifier: unregister
focal_class.modifiers: public
focal_class.parameters: (String noteId, String className, String event)
focal_class.return: void
focal_class.signature: void unregister(String noteId, String className, String event)
focal_class.class_method_signature: InterpreterHookRegistry.get(String noteId, String className, String event)
focal_class.full_signature: public String get(String noteId, String className, String event)
focal_class.identifier: get
focal_class.modifiers: public
focal_class.parameters: (String noteId, String className, String event)
focal_class.return: String
focal_class.signature: String get(String noteId, String className, String event)
focal_method.body: public void register(String noteId, String className,
                         String event, String cmd) throws IllegalArgumentException {
      synchronized (registry) {
        if (noteId == null) {
          noteId = GLOBAL_KEY;
        }
        addRepl(noteId, className);
        if (!event.equals(HookType.POST_EXEC) && !event.equals(HookType.PRE_EXEC) &&
            !event.equals(HookType.POST_EXEC_DEV) && !event.equals(HookType.PRE_EXEC_DEV)) {
          throw new IllegalArgumentException("Must be " + HookType.POST_EXEC + ", " +
                                                          HookType.POST_EXEC_DEV + ", " +
                                                          HookType.PRE_EXEC + " or " +
                                                          HookType.PRE_EXEC_DEV);
        }
        registry.get(noteId).get(className).put(event, cmd);
      }
    }
focal_method.class_method_signature: InterpreterHookRegistry.register(String noteId, String className,
                         String event, String cmd)
focal_method.full_signature: public void register(String noteId, String className,
                         String event, String cmd)
focal_method.identifier: register
focal_method.invocations: addRepl equals equals equals equals put get get
focal_method.modifiers: public
focal_method.parameters: (String noteId, String className,
                         String event, String cmd)
focal_method.return: void
focal_method.signature: void register(String noteId, String className,
                         String event, String cmd)