public static String makeDeepLink ( String link ) { if ( link != null // If getCurrentRemoteConnectionLink() == null means there is no current remote connection && getCurrentRemoteConnectionLink ( ) != null // If containsRemoteParameter(link) is true means link already contain remote connection parameter && ! containsRemoteParameter ( link ) ) { link += ( link . contains ( "?" ) ? "&" : "?" ) + PARAM_REMOTE_CONNECTION + "=" + getCurrentRemoteConnectionLink ( ) ; } return link ; }
Adds remote connection parameter to link GET query if parameter yet not present in this link .