+
+ if ( $id =~ /^\d+$/ ) {
+ if ( $id ne $obj->Id ) {
+ die 'Loaded object id ' . $obj->Id . " is different from passed id $id";
+ }
+ }
+ else {
+ if ( $obj->_Accessible( 'Name', 'read' ) && $id ne $obj->Name ) {
+ die 'Loaded object name ' . $obj->Name . " is different from passed name $id";
+ }
+ }