Code example for List

Methods: clear

0
        mTransitionTarget = State.UNKNOWN;
    } 
 
    // Reinitialize the network state 
    public void resetNetworkState() { 
        mStateDepository.clear();
        mTransitionDirection = DO_NOTHING;
        mTransitionTarget = State.UNKNOWN;
    } 
 
    // set the transition criteria, transitionDir could be: 
    // DO_NOTHING, TO_CONNECTION, TO_DISCONNECTION 
    public void setStateTransitionCriteria(State initState, int transitionDir, State targetState) {
        if (!mStateDepository.isEmpty()) {
            mStateDepository.clear();
        } 
        mStateDepository.add(initState);
        mTransitionDirection = transitionDir;
        mTransitionTarget = targetState;
        Log.v(LOG_TAG, "setStateTransitionCriteria: " + printStates());
    }