MODIFIED THE CONNECTION STATE INTEGERS AND METHODS