api/jar/src/main/java/javax/slee/management/ServiceState.java
public static ServiceState fromString(String state) throws NullPointerException, IllegalArgumentException {
        if (state == null) throw new NullPointerException("state is null");
        if (state.equalsIgnoreCase(INACTIVE_STRING)) return INACTIVE;
        if (state.equalsIgnoreCase(ACTIVE_STRING)) return ACTIVE;
        if (state.equalsIgnoreCase(STOPPING_STRING)) return STOPPING;
        throw new IllegalArgumentException("Invalid state: " + state);
    }
public static ServiceState fromString(String state) throws NullPointerException, IllegalArgumentException {
        if (state == null) throw new NullPointerException("state is null");
        if (state.equalsIgnoreCase(INACTIVE_STRING)) return INACTIVE;
        if (state.equalsIgnoreCase(ACTIVE_STRING)) return ACTIVE;
        if (state.equalsIgnoreCase(STOPPING_STRING)) return STOPPING;
        throw new IllegalArgumentException("Invalid state: " + state);
    }
public static ServiceState fromString ( String state ) throws NullPointerException , IllegalArgumentException { if ( state == null ) throw new NullPointerException ( "state is null" ) ; if ( state . equalsIgnoreCase ( INACTIVE_STRING ) ) return INACTIVE ; if ( state . equalsIgnoreCase ( ACTIVE_STRING ) ) return ACTIVE ; if ( state . equalsIgnoreCase ( STOPPING_STRING ) ) return STOPPING ; throw new IllegalArgumentException ( "Invalid state: " + state ) ; }
Get a <code>ServiceState</code> object from an integer value.
@param state the state as a string, for example as returned by the {@link #toString()}
method (case insensitive).
@return a <code>ServiceState</code> object corresponding to <code>state</code>.
@throws NullPointerException if <code>state</code> is <code>null</code>.
@throws IllegalArgumentException if <code>state</code> is not a valid service
state string.
@since SLEE 1.1
Get a <code > ServiceState< / code > object from an integer value .