Previous CloneSet | Next CloneSet | Back to Main Report |
Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
---|---|---|---|---|
12 | 2 | 0 | 1.000 | class_member |
Clone Abstraction | Parameter Bindings |
Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
---|---|---|---|
1 | 12 | 204 | plugins/authentication/openid/Auth/OpenID/Parse.php |
2 | 12 | 100 | plugins/authentication/openid/Auth/Yadis/ParseHTML.php |
| ||||
function removeQuotes($str) { $matches= array(); $double= '/^"(.*)"$/'; $single= "/^\\'(.*)\\'\$/"; if (preg_match($double, $str, $matches)) { return $matches[1]; } else if (preg_match($single, $str, $matches)) { return $matches[1]; } else { return $str; } } |
| ||||
/** * Strip single and double quotes off of a string, if they are * present. * * @access private * @param string $str The original string * @return string $new_str The new string with leading and * trailing quotes removed */ function removeQuotes($str) { $matches= array(); $double= '/^"(.*)"$/'; $single= "/^\\'(.*)\\'\$/"; if (preg_match($double, $str, $matches)) { return $matches[1]; } else if (preg_match($single, $str, $matches)) { return $matches[1]; } else { return $str; } } |
| |||
/** * Strip single and double quotes off of a string, if they are * present. * * @access private * @param string $str The original string * @return string $new_str The new string with leading and * trailing quotes removed */ function removeQuotes($str) { $matches=array(); $double='/^"(.*)"$/'; $single="/^\\'(.*)\\'\$/"; if (preg_match($double,$str,$matches)) { return $matches[1]; } else if (preg_match($single,$str,$matches)) { return $matches[1]; } else { return $str; } } |
CloneAbstraction |
Parameter Index | Clone Instance | Parameter Name | Value |
---|---|---|---|
None |