fn from_authority(_attr: &String, _authority: &String) -> bool {
    let v: Vec<_> = _attr.match_indices("::").collect();
    if v.len() == 1 {
        return _attr.get(0..v[0].0).unwrap().to_string() == _authority.to_string();
    }
    return false;
}
/// BDABE Scheme helper function: from_authority
/// Returns true if a specific attribute is handled by a given authority.
/// Please adopt or implement you own logic. Right now the algorithm checks if the first part
/// of an attribute up to "::" is equal with the authority name.
/// i.e. Attribute: "Fraunhofer::User" is handled by Fraunhofer = true
///      Attribute: "BWM::User" is handled by Fraunhofer = false
///
/// # Arguments
///
///	* `_attr` - Name of the attribute given as String
///	* `_sk` - Name of the auhtority given as String
///
BDABE Scheme helper function: from_authority
Returns true if a specific attribute is handled by a given authority.
Please adopt or implement you own logic. Right now the algorithm checks if the first part
of an attribute up to "::" is equal with the authority name.
BDABE Scheme helper function : from_authority Returns true if a specific attribute is handled by a given authority . Please adopt or implement you own logic . Right now the algorithm checks if the first part of an attribute up to " :: " is equal with the authority name .
fn from_authority(_attr: &String, _authority: &String) -> bool {
    let v: Vec<_> = _attr.match_indices("::").collect();
    if v.len() == 1 {
        return _attr.get(0..v[0].0).unwrap().to_string() == _authority.to_string();
    }
    return false;
}
fn from_authority ( _attr : & String , _authority : & String ) -> bool { let v : Vec < _ > = _attr . match_indices ( " " ) . collect ( ) ; if v . len ( ) == 1 { return _attr . get ( 0 .. v [ 0 ] . 0 ) . unwrap ( ) . to_string ( ) == _authority . to_string ( ) ; } return false ; }
BDABE Scheme helper function: from_authority
Returns true if a specific attribute is handled by a given authority.
BDABE Scheme helper function : from_authority Returns true if a specific attribute is handled by a given authority .
_attr
&String
_authority
&String
_attr
&String
_authority
&String