public int subscribe_count ( final String pattern ) throws InvalidInputException , TerminateException { OtpOutputStream subscribe_count = new OtpOutputStream ( ) ; subscribe_count . write ( OtpExternal . versionTag ) ; final OtpErlangObject [ ] tuple = { new OtpErlangAtom ( "subscribe_count" ) , new OtpErlangString ( pattern ) } ; subscribe_count . write_any ( new OtpErlangTuple ( tuple ) ) ; send ( subscribe_count ) ; try { return ( Integer ) poll_request ( null , false ) ; } catch ( MessageDecodingException e ) { e . printStackTrace ( API . err ) ; return - 1 ; } }
Determine how may service name pattern subscriptions have occurred .