@declared
def get_custom(obj_ref, cname, default=None):
 obj = get_objects(obj_ref)
 if (not obj):
  return default
 cname = cname.upper().strip()
 if (not cname.startswith('_')):
  cname = ('_' + cname)
 return obj.customs.get(cname, default)

@ declared def get_custom ( obj_ref , cname , default = None ) : obj = get_objects ( obj_ref ) if ( not obj ) : return default cname = cname . upper ( ) . strip ( ) if ( not cname . startswith ( '_' ) ) : cname = ( '_' + cname ) return obj . customs . get ( cname , default )
get custom varialbe from a service or a host .