apps/bmp/protocol/src/main/java/org/onosproject/bmp/controller/BmpSessionManager.java
/**
     * Extracts properties from the component configuration context.
     *
     * @param context the component context
     */
Extracts properties from the component configuration context.
@param context the component context
Extracts properties from the component configuration context . @param context the component context
private void readComponentConfiguration(ComponentContext context) {
        Dictionary<?, ?> properties = context.getProperties();
        try {
            String strPort = (String) properties.get("bmpPort");
            if (strPort != null) {
                bmpPort = Integer.parseInt(strPort);
            } else {
                bmpPort = DEFAULT_BMP_PORT;
            }
        } catch (NumberFormatException | ClassCastException e) {
            bmpPort = DEFAULT_BMP_PORT;
        }
        log.debug("BMP port is set to {}", bmpPort);
    }
private void readComponentConfiguration ( ComponentContext context ) { Dictionary < ? , ? > properties = context . getProperties ( ) ; try { String strPort = ( String ) properties . get ( "bmpPort" ) ; if ( strPort != null ) { bmpPort = Integer . parseInt ( strPort ) ; } else { bmpPort = DEFAULT_BMP_PORT ; } } catch ( NumberFormatException | ClassCastException e ) { bmpPort = DEFAULT_BMP_PORT ; } log . debug ( "BMP port is set to {}" , bmpPort ) ; }
Extracts properties from the component configuration context.
Extracts properties from the component configuration context .