package com.github.dockerjava.api.model;

import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;

import javax.annotation.Nonnull;
import java.util.HashMap;
import java.util.Map;

/**
 * @since 1.24
 */
public enum EventType {
    /**
     * @since 1.24
     */
    CONTAINER("container"),

    /**
     * @since 1.24
     */
    DAEMON("daemon"),

    /**
     * @since 1.24
     */
    IMAGE("image"),
    NETWORK("network"),
    PLUGIN("plugin"),
    VOLUME("volume");

    private static final Map<String, EventType> EVENT_TYPES = new HashMap<>();

    static {
        for (EventType t : values()) {
            EVENT_TYPES.put(t.name().toLowerCase(), t);
        }
    }

    private String value;

    EventType(@Nonnull String value) {
        this.value = value;
    }

    @JsonValue
    public String getValue() {
        return value;
    }

    @JsonCreator
    public static EventType forValue(String s) {
        return EVENT_TYPES.get(s);
    }
}

@@ -269,16 +269,38 @@
 tType %7B%0A
+    CONFIG(%22config%22),%0A
     /**%0A
@@ -500,22 +500,86 @@
     
-PLUGIN(%22plugin
+NODE(%22node%22),%0A    PLUGIN(%22plugin%22),%0A    SECRET(%22secret%22),%0A    SERVICE(%22service
 %22),%0A

Add other event types (#1366)