home *** CD-ROM | disk | FTP | other *** search
/ Mobiclic 136 / MOBICLIC136.ISO / pc / DATA / HOTE / libs / amfphp / amfphp.swf / scripts / __Packages / mx / rpc / Fault.as < prev    next >
Text File  |  2011-07-20  |  1KB  |  54 lines

  1. class mx.rpc.Fault extends Object
  2. {
  3.    function Fault(code, msg, detail, type)
  4.    {
  5.       var _loc1_ = this;
  6.       super();
  7.       _loc1_.__faultcode = code;
  8.       _loc1_.__faultstring = msg;
  9.       _loc1_.__detail = detail;
  10.       _loc1_.__type = type;
  11.    }
  12.    function get faultcode()
  13.    {
  14.       return this.__faultcode;
  15.    }
  16.    function get faultstring()
  17.    {
  18.       return this.__faultstring;
  19.    }
  20.    function get detail()
  21.    {
  22.       return this.__detail;
  23.    }
  24.    function get description()
  25.    {
  26.       var _loc2_ = this;
  27.       if(_loc2_.__description == null)
  28.       {
  29.          if(_loc2_.__faultstring.indexOf(":") > -1)
  30.          {
  31.             _loc2_.__description = _loc2_.__faultstring.substring(_loc2_.__faultstring.indexOf(":") + 1);
  32.             var _loc1_ = 0;
  33.             while(_loc2_.__description.indexOf(" ",_loc1_) == _loc1_)
  34.             {
  35.                _loc1_ = _loc1_ + 1;
  36.             }
  37.             if(_loc1_ > 0)
  38.             {
  39.                _loc2_.__description = _loc2_.__description.substring(_loc1_);
  40.             }
  41.          }
  42.          else
  43.          {
  44.             _loc2_.__description = _loc2_.__faultstring;
  45.          }
  46.       }
  47.       return _loc2_.__description;
  48.    }
  49.    function get type()
  50.    {
  51.       return this.__type;
  52.    }
  53. }
  54.