<s> from google . net . proto import ProtocolBuffer <EOL> import array <EOL> import dummy_thread as thread <EOL> __pychecker__ = """<STR_LIT>""" <EOL> if hasattr ( ProtocolBuffer , '<STR_LIT>' ) : <EOL> _extension_runtime = True <EOL> _ExtendableProtocolMessage = ProtocolBuffer . ExtendableProtocolMessage <EOL> else : <EOL> _extension_runtime = False <EOL> _ExtendableProtocolMessage = ProtocolBuffer . ProtocolMessage <EOL> class URLFetchServiceError ( ProtocolBuffer . ProtocolMessage ) : <EOL> OK = <NUM_LIT:0> <EOL> INVALID_URL = <NUM_LIT:1> <EOL> FETCH_ERROR = <NUM_LIT:2> <EOL> UNSPECIFIED_ERROR = <NUM_LIT:3> <EOL> RESPONSE_TOO_LARGE = <NUM_LIT:4> <EOL> DEADLINE_EXCEEDED = <NUM_LIT:5> <EOL> SSL_CERTIFICATE_ERROR = <NUM_LIT:6> <EOL> DNS_ERROR = <NUM_LIT:7> <EOL> CLOSED = <NUM_LIT:8> <EOL> INTERNAL_TRANSIENT_ERROR = <NUM_LIT:9> <EOL> TOO_MANY_REDIRECTS = <NUM_LIT:10> <EOL> MALFORMED_REPLY = <NUM_LIT:11> <EOL> CONNECTION_ERROR = <NUM_LIT:12> <EOL> _ErrorCode_NAMES = { <EOL> <NUM_LIT:0> : "<STR_LIT:OK>" , <EOL> <NUM_LIT:1> : "<STR_LIT>" , <EOL> <NUM_LIT:2> : "<STR_LIT>" , <EOL> <NUM_LIT:3> : "<STR_LIT>" , <EOL> <NUM_LIT:4> : "<STR_LIT>" , <EOL> <NUM_LIT:5> : "<STR_LIT>" , <EOL> <NUM_LIT:6> : "<STR_LIT>" , <EOL> <NUM_LIT:7> : "<STR_LIT>" , <EOL> <NUM_LIT:8> : "<STR_LIT>" , <EOL> <NUM_LIT:9> : "<STR_LIT>" , <EOL> <NUM_LIT:10> : "<STR_LIT>" , <EOL> <NUM_LIT:11> : "<STR_LIT>" , <EOL> <NUM_LIT:12> : "<STR_LIT>" , <EOL> } <EOL> def ErrorCode_Name ( cls , x ) : return cls . _ErrorCode_NAMES . get ( x , "<STR_LIT>" ) <EOL> ErrorCode_Name = classmethod ( ErrorCode_Name ) <EOL> def __init__ ( self , contents = None ) : <EOL> pass <EOL> if contents is not None : self . MergeFromString ( contents ) <EOL> def MergeFrom ( self , x ) : <EOL> assert x is not self <EOL> def Equals ( self , x ) : <EOL> if x is self : return <NUM_LIT:1> <EOL> return <NUM_LIT:1> <EOL> def IsInitialized ( self , debug_strs = None ) : <EOL> initialized = <NUM_LIT:1> <EOL> return initialized <EOL> def ByteSize ( self ) : <EOL> n = <NUM_LIT:0> <EOL> return n <EOL> def ByteSizePartial ( self ) : <EOL> n = <NUM_LIT:0> <EOL> return n <EOL> def Clear ( self ) : <EOL> pass <EOL> def OutputUnchecked ( self , out ) : <EOL> pass <EOL> def OutputPartial ( self , out ) : <EOL> pass <EOL> def TryMerge ( self , d ) : <EOL> while d . avail ( ) > <NUM_LIT:0> : <EOL> tt = d . getVarInt32 ( ) <EOL> if ( tt == <NUM_LIT:0> ) : raise ProtocolBuffer . ProtocolBufferDecodeError <EOL> d . skipData ( tt ) <EOL> def __str__ ( self , prefix = "<STR_LIT>" , printElemNumber = <NUM_LIT:0> ) : <EOL> res = "<STR_LIT>" <EOL> return res <EOL> def _BuildTagLookupTable ( sparse , maxtag , default = None ) : <EOL> return tuple ( [ sparse . get ( i , default ) for i in xrange ( <NUM_LIT:0> , <NUM_LIT:1> + maxtag ) ] ) <EOL> _TEXT = _BuildTagLookupTable ( { <EOL> <NUM_LIT:0> : "<STR_LIT>" , <EOL> } , <NUM_LIT:0> ) <EOL> _TYPES = _BuildTagLookupTable ( { <EOL> <NUM_LIT:0> : ProtocolBuffer . Encoder . NUMERIC , <EOL> } , <NUM_LIT:0> , ProtocolBuffer . Encoder . MAX_TYPE ) <EOL> _STYLE = """<STR_LIT>""" <EOL> _STYLE_CONTENT_TYPE = """<STR_LIT>""" <EOL> _PROTO_DESCRIPTOR_NAME = '<STR_LIT>' <EOL> class URLFetchRequest_Header ( ProtocolBuffer . ProtocolMessage ) : <EOL> has_key_ = <NUM_LIT:0> <EOL> key_ = "<STR_LIT>" <EOL> has_value_ = <NUM_LIT:0> <EOL> value_ = "<STR_LIT>" <EOL> def __init__ ( self , contents = None ) : <EOL> if contents is not None : self . MergeFromString ( contents ) <EOL> def key ( self ) : return self . key_ <EOL> def set_key ( self , x ) : <EOL> self . has_key_ = <NUM_LIT:1> <EOL> self . key_ = x <EOL> def clear_key ( self ) : <EOL> if self . has_key_ : <EOL> self . has_key_ = <NUM_LIT:0> <EOL> self . key_ = "<STR_LIT>" <EOL> def has_key ( self ) : return self . has_key_ <EOL> def value ( self ) : return self . value_ <EOL> def set_value ( self , x ) : <EOL> self . has_value_ = <NUM_LIT:1> <EOL> self . value_ = x <EOL> def clear_value ( self ) : <EOL> if self . has_value_ : <EOL> self . has_value_ = <NUM_LIT:0> <EOL> self . value_ = "<STR_LIT>" <EOL> def has_value ( self ) : return self . has_value_ <EOL> def MergeFrom ( self , x ) : <EOL> assert x is not self <EOL> if ( x . has_key ( ) ) : self . set_key ( x . key ( ) ) <EOL> if ( x . has_value ( ) ) : self . set_value ( x . value ( ) ) <EOL> def Equals ( self , x ) : <EOL> if x is self : return <NUM_LIT:1> <EOL> if self . has_key_ != x . has_key_ : return <NUM_LIT:0> <EOL> if self . has_key_ and self . key_ != x . key_ : return <NUM_LIT:0> <EOL> if self . has_value_ != x . has_value_ : return <NUM_LIT:0> <EOL> if self . has_value_ and self . value_ != x . value_ : return <NUM_LIT:0> <EOL> return <NUM_LIT:1> <EOL> def IsInitialized ( self , debug_strs = None ) : <EOL> initialized = <NUM_LIT:1> <EOL> if ( not self . has_key_ ) : <EOL> initialized = <NUM_LIT:0> <EOL> if debug_strs is not None : <EOL> debug_strs . append ( '<STR_LIT>' ) <EOL> if ( not self . has_value_ ) : <EOL> initialized = <NUM_LIT:0> <EOL> if debug_strs is not None : <EOL> debug_strs . append ( '<STR_LIT>' ) <EOL> return initialized <EOL> def ByteSize ( self ) : <EOL> n = <NUM_LIT:0> <EOL> n += self . lengthString ( len ( self . key_ ) ) <EOL> n += self . lengthString ( len ( self . value_ ) ) <EOL> return n + <NUM_LIT:2> <EOL> def ByteSizePartial ( self ) : <EOL> n = <NUM_LIT:0> <EOL> if ( self . has_key_ ) : <EOL> n += <NUM_LIT:1> <EOL> n += self . lengthString ( len ( self . key_ ) ) <EOL> if ( self . has_value_ ) : <EOL> n += <NUM_LIT:1> <EOL> n += self . lengthString ( len ( self . value_ ) ) <EOL> return n <EOL> def Clear ( self ) : <EOL> self . clear_key ( ) <EOL> self . clear_value ( ) <EOL> def OutputUnchecked ( self , out ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putPrefixedString ( self . key_ ) <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putPrefixedString ( self . value_ ) <EOL> def OutputPartial ( self , out ) : <EOL> if ( self . has_key_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putPrefixedString ( self . key_ ) <EOL> if ( self . has_value_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putPrefixedString ( self . value_ ) <EOL> def TryMerge ( self , d ) : <EOL> while <NUM_LIT:1> : <EOL> tt = d . getVarInt32 ( ) <EOL> if tt == <NUM_LIT> : break <EOL> if tt == <NUM_LIT> : <EOL> self . set_key ( d . getPrefixedString ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . set_value ( d . getPrefixedString ( ) ) <EOL> continue <EOL> if ( tt == <NUM_LIT:0> ) : raise ProtocolBuffer . ProtocolBufferDecodeError <EOL> d . skipData ( tt ) <EOL> def __str__ ( self , prefix = "<STR_LIT>" , printElemNumber = <NUM_LIT:0> ) : <EOL> res = "<STR_LIT>" <EOL> if self . has_key_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatString ( self . key_ ) ) <EOL> if self . has_value_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatString ( self . value_ ) ) <EOL> return res <EOL> class URLFetchRequest ( ProtocolBuffer . ProtocolMessage ) : <EOL> GET = <NUM_LIT:1> <EOL> POST = <NUM_LIT:2> <EOL> HEAD = <NUM_LIT:3> <EOL> PUT = <NUM_LIT:4> <EOL> DELETE = <NUM_LIT:5> <EOL> PATCH = <NUM_LIT:6> <EOL> _RequestMethod_NAMES = { <EOL> <NUM_LIT:1> : "<STR_LIT:GET>" , <EOL> <NUM_LIT:2> : "<STR_LIT:POST>" , <EOL> <NUM_LIT:3> : "<STR_LIT>" , <EOL> <NUM_LIT:4> : "<STR_LIT>" , <EOL> <NUM_LIT:5> : "<STR_LIT>" , <EOL> <NUM_LIT:6> : "<STR_LIT>" , <EOL> } <EOL> def RequestMethod_Name ( cls , x ) : return cls . _RequestMethod_NAMES . get ( x , "<STR_LIT>" ) <EOL> RequestMethod_Name = classmethod ( RequestMethod_Name ) <EOL> has_method_ = <NUM_LIT:0> <EOL> method_ = <NUM_LIT:0> <EOL> has_url_ = <NUM_LIT:0> <EOL> url_ = "<STR_LIT>" <EOL> has_payload_ = <NUM_LIT:0> <EOL> payload_ = "<STR_LIT>" <EOL> has_followredirects_ = <NUM_LIT:0> <EOL> followredirects_ = <NUM_LIT:1> <EOL> has_deadline_ = <NUM_LIT:0> <EOL> deadline_ = <NUM_LIT:0.0> <EOL> has_mustvalidateservercertificate_ = <NUM_LIT:0> <EOL> mustvalidateservercertificate_ = <NUM_LIT:1> <EOL> def __init__ ( self , contents = None ) : <EOL> self . header_ = [ ] <EOL> if contents is not None : self . MergeFromString ( contents ) <EOL> def method ( self ) : return self . method_ <EOL> def set_method ( self , x ) : <EOL> self . has_method_ = <NUM_LIT:1> <EOL> self . method_ = x <EOL> def clear_method ( self ) : <EOL> if self . has_method_ : <EOL> self . has_method_ = <NUM_LIT:0> <EOL> self . method_ = <NUM_LIT:0> <EOL> def has_method ( self ) : return self . has_method_ <EOL> def url ( self ) : return self . url_ <EOL> def set_url ( self , x ) : <EOL> self . has_url_ = <NUM_LIT:1> <EOL> self . url_ = x <EOL> def clear_url ( self ) : <EOL> if self . has_url_ : <EOL> self . has_url_ = <NUM_LIT:0> <EOL> self . url_ = "<STR_LIT>" <EOL> def has_url ( self ) : return self . has_url_ <EOL> def header_size ( self ) : return len ( self . header_ ) <EOL> def header_list ( self ) : return self . header_ <EOL> def header ( self , i ) : <EOL> return self . header_ [ i ] <EOL> def mutable_header ( self , i ) : <EOL> return self . header_ [ i ] <EOL> def add_header ( self ) : <EOL> x = URLFetchRequest_Header ( ) <EOL> self . header_ . append ( x ) <EOL> return x <EOL> def clear_header ( self ) : <EOL> self . header_ = [ ] <EOL> def payload ( self ) : return self . payload_ <EOL> def set_payload ( self , x ) : <EOL> self . has_payload_ = <NUM_LIT:1> <EOL> self . payload_ = x <EOL> def clear_payload ( self ) : <EOL> if self . has_payload_ : <EOL> self . has_payload_ = <NUM_LIT:0> <EOL> self . payload_ = "<STR_LIT>" <EOL> def has_payload ( self ) : return self . has_payload_ <EOL> def followredirects ( self ) : return self . followredirects_ <EOL> def set_followredirects ( self , x ) : <EOL> self . has_followredirects_ = <NUM_LIT:1> <EOL> self . followredirects_ = x <EOL> def clear_followredirects ( self ) : <EOL> if self . has_followredirects_ : <EOL> self . has_followredirects_ = <NUM_LIT:0> <EOL> self . followredirects_ = <NUM_LIT:1> <EOL> def has_followredirects ( self ) : return self . has_followredirects_ <EOL> def deadline ( self ) : return self . deadline_ <EOL> def set_deadline ( self , x ) : <EOL> self . has_deadline_ = <NUM_LIT:1> <EOL> self . deadline_ = x <EOL> def clear_deadline ( self ) : <EOL> if self . has_deadline_ : <EOL> self . has_deadline_ = <NUM_LIT:0> <EOL> self . deadline_ = <NUM_LIT:0.0> <EOL> def has_deadline ( self ) : return self . has_deadline_ <EOL> def mustvalidateservercertificate ( self ) : return self . mustvalidateservercertificate_ <EOL> def set_mustvalidateservercertificate ( self , x ) : <EOL> self . has_mustvalidateservercertificate_ = <NUM_LIT:1> <EOL> self . mustvalidateservercertificate_ = x <EOL> def clear_mustvalidateservercertificate ( self ) : <EOL> if self . has_mustvalidateservercertificate_ : <EOL> self . has_mustvalidateservercertificate_ = <NUM_LIT:0> <EOL> self . mustvalidateservercertificate_ = <NUM_LIT:1> <EOL> def has_mustvalidateservercertificate ( self ) : return self . has_mustvalidateservercertificate_ <EOL> def MergeFrom ( self , x ) : <EOL> assert x is not self <EOL> if ( x . has_method ( ) ) : self . set_method ( x . method ( ) ) <EOL> if ( x . has_url ( ) ) : self . set_url ( x . url ( ) ) <EOL> for i in xrange ( x . header_size ( ) ) : self . add_header ( ) . CopyFrom ( x . header ( i ) ) <EOL> if ( x . has_payload ( ) ) : self . set_payload ( x . payload ( ) ) <EOL> if ( x . has_followredirects ( ) ) : self . set_followredirects ( x . followredirects ( ) ) <EOL> if ( x . has_deadline ( ) ) : self . set_deadline ( x . deadline ( ) ) <EOL> if ( x . has_mustvalidateservercertificate ( ) ) : self . set_mustvalidateservercertificate ( x . mustvalidateservercertificate ( ) ) <EOL> def Equals ( self , x ) : <EOL> if x is self : return <NUM_LIT:1> <EOL> if self . has_method_ != x . has_method_ : return <NUM_LIT:0> <EOL> if self . has_method_ and self . method_ != x . method_ : return <NUM_LIT:0> <EOL> if self . has_url_ != x . has_url_ : return <NUM_LIT:0> <EOL> if self . has_url_ and self . url_ != x . url_ : return <NUM_LIT:0> <EOL> if len ( self . header_ ) != len ( x . header_ ) : return <NUM_LIT:0> <EOL> for e1 , e2 in zip ( self . header_ , x . header_ ) : <EOL> if e1 != e2 : return <NUM_LIT:0> <EOL> if self . has_payload_ != x . has_payload_ : return <NUM_LIT:0> <EOL> if self . has_payload_ and self . payload_ != x . payload_ : return <NUM_LIT:0> <EOL> if self . has_followredirects_ != x . has_followredirects_ : return <NUM_LIT:0> <EOL> if self . has_followredirects_ and self . followredirects_ != x . followredirects_ : return <NUM_LIT:0> <EOL> if self . has_deadline_ != x . has_deadline_ : return <NUM_LIT:0> <EOL> if self . has_deadline_ and self . deadline_ != x . deadline_ : return <NUM_LIT:0> <EOL> if self . has_mustvalidateservercertificate_ != x . has_mustvalidateservercertificate_ : return <NUM_LIT:0> <EOL> if self . has_mustvalidateservercertificate_ and self . mustvalidateservercertificate_ != x . mustvalidateservercertificate_ : return <NUM_LIT:0> <EOL> return <NUM_LIT:1> <EOL> def IsInitialized ( self , debug_strs = None ) : <EOL> initialized = <NUM_LIT:1> <EOL> if ( not self . has_method_ ) : <EOL> initialized = <NUM_LIT:0> <EOL> if debug_strs is not None : <EOL> debug_strs . append ( '<STR_LIT>' ) <EOL> if ( not self . has_url_ ) : <EOL> initialized = <NUM_LIT:0> <EOL> if debug_strs is not None : <EOL> debug_strs . append ( '<STR_LIT>' ) <EOL> for p in self . header_ : <EOL> if not p . IsInitialized ( debug_strs ) : initialized = <NUM_LIT:0> <EOL> return initialized <EOL> def ByteSize ( self ) : <EOL> n = <NUM_LIT:0> <EOL> n += self . lengthVarInt64 ( self . method_ ) <EOL> n += self . lengthString ( len ( self . url_ ) ) <EOL> n += <NUM_LIT:2> * len ( self . header_ ) <EOL> for i in xrange ( len ( self . header_ ) ) : n += self . header_ [ i ] . ByteSize ( ) <EOL> if ( self . has_payload_ ) : n += <NUM_LIT:1> + self . lengthString ( len ( self . payload_ ) ) <EOL> if ( self . has_followredirects_ ) : n += <NUM_LIT:2> <EOL> if ( self . has_deadline_ ) : n += <NUM_LIT:9> <EOL> if ( self . has_mustvalidateservercertificate_ ) : n += <NUM_LIT:2> <EOL> return n + <NUM_LIT:2> <EOL> def ByteSizePartial ( self ) : <EOL> n = <NUM_LIT:0> <EOL> if ( self . has_method_ ) : <EOL> n += <NUM_LIT:1> <EOL> n += self . lengthVarInt64 ( self . method_ ) <EOL> if ( self . has_url_ ) : <EOL> n += <NUM_LIT:1> <EOL> n += self . lengthString ( len ( self . url_ ) ) <EOL> n += <NUM_LIT:2> * len ( self . header_ ) <EOL> for i in xrange ( len ( self . header_ ) ) : n += self . header_ [ i ] . ByteSizePartial ( ) <EOL> if ( self . has_payload_ ) : n += <NUM_LIT:1> + self . lengthString ( len ( self . payload_ ) ) <EOL> if ( self . has_followredirects_ ) : n += <NUM_LIT:2> <EOL> if ( self . has_deadline_ ) : n += <NUM_LIT:9> <EOL> if ( self . has_mustvalidateservercertificate_ ) : n += <NUM_LIT:2> <EOL> return n <EOL> def Clear ( self ) : <EOL> self . clear_method ( ) <EOL> self . clear_url ( ) <EOL> self . clear_header ( ) <EOL> self . clear_payload ( ) <EOL> self . clear_followredirects ( ) <EOL> self . clear_deadline ( ) <EOL> self . clear_mustvalidateservercertificate ( ) <EOL> def OutputUnchecked ( self , out ) : <EOL> out . putVarInt32 ( <NUM_LIT:8> ) <EOL> out . putVarInt32 ( self . method_ ) <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putPrefixedString ( self . url_ ) <EOL> for i in xrange ( len ( self . header_ ) ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> self . header_ [ i ] . OutputUnchecked ( out ) <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> if ( self . has_payload_ ) : <EOL> out . putVarInt32 ( <NUM_LIT:50> ) <EOL> out . putPrefixedString ( self . payload_ ) <EOL> if ( self . has_followredirects_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putBoolean ( self . followredirects_ ) <EOL> if ( self . has_deadline_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putDouble ( self . deadline_ ) <EOL> if ( self . has_mustvalidateservercertificate_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putBoolean ( self . mustvalidateservercertificate_ ) <EOL> def OutputPartial ( self , out ) : <EOL> if ( self . has_method_ ) : <EOL> out . putVarInt32 ( <NUM_LIT:8> ) <EOL> out . putVarInt32 ( self . method_ ) <EOL> if ( self . has_url_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putPrefixedString ( self . url_ ) <EOL> for i in xrange ( len ( self . header_ ) ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> self . header_ [ i ] . OutputPartial ( out ) <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> if ( self . has_payload_ ) : <EOL> out . putVarInt32 ( <NUM_LIT:50> ) <EOL> out . putPrefixedString ( self . payload_ ) <EOL> if ( self . has_followredirects_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putBoolean ( self . followredirects_ ) <EOL> if ( self . has_deadline_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putDouble ( self . deadline_ ) <EOL> if ( self . has_mustvalidateservercertificate_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putBoolean ( self . mustvalidateservercertificate_ ) <EOL> def TryMerge ( self , d ) : <EOL> while d . avail ( ) > <NUM_LIT:0> : <EOL> tt = d . getVarInt32 ( ) <EOL> if tt == <NUM_LIT:8> : <EOL> self . set_method ( d . getVarInt32 ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . set_url ( d . getPrefixedString ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . add_header ( ) . TryMerge ( d ) <EOL> continue <EOL> if tt == <NUM_LIT:50> : <EOL> self . set_payload ( d . getPrefixedString ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . set_followredirects ( d . getBoolean ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . set_deadline ( d . getDouble ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . set_mustvalidateservercertificate ( d . getBoolean ( ) ) <EOL> continue <EOL> if ( tt == <NUM_LIT:0> ) : raise ProtocolBuffer . ProtocolBufferDecodeError <EOL> d . skipData ( tt ) <EOL> def __str__ ( self , prefix = "<STR_LIT>" , printElemNumber = <NUM_LIT:0> ) : <EOL> res = "<STR_LIT>" <EOL> if self . has_method_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatInt32 ( self . method_ ) ) <EOL> if self . has_url_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatString ( self . url_ ) ) <EOL> cnt = <NUM_LIT:0> <EOL> for e in self . header_ : <EOL> elm = "<STR_LIT>" <EOL> if printElemNumber : elm = "<STR_LIT>" % cnt <EOL> res += prefix + ( "<STR_LIT>" % elm ) <EOL> res += e . __str__ ( prefix + "<STR_LIT:U+0020>" , printElemNumber ) <EOL> res += prefix + "<STR_LIT>" <EOL> cnt += <NUM_LIT:1> <EOL> if self . has_payload_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatString ( self . payload_ ) ) <EOL> if self . has_followredirects_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatBool ( self . followredirects_ ) ) <EOL> if self . has_deadline_ : res += prefix + ( "<STR_LIT>" % self . DebugFormat ( self . deadline_ ) ) <EOL> if self . has_mustvalidateservercertificate_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatBool ( self . mustvalidateservercertificate_ ) ) <EOL> return res <EOL> def _BuildTagLookupTable ( sparse , maxtag , default = None ) : <EOL> return tuple ( [ sparse . get ( i , default ) for i in xrange ( <NUM_LIT:0> , <NUM_LIT:1> + maxtag ) ] ) <EOL> kMethod = <NUM_LIT:1> <EOL> kUrl = <NUM_LIT:2> <EOL> kHeaderGroup = <NUM_LIT:3> <EOL> kHeaderKey = <NUM_LIT:4> <EOL> kHeaderValue = <NUM_LIT:5> <EOL> kPayload = <NUM_LIT:6> <EOL> kFollowRedirects = <NUM_LIT:7> <EOL> kDeadline = <NUM_LIT:8> <EOL> kMustValidateServerCertificate = <NUM_LIT:9> <EOL> _TEXT = _BuildTagLookupTable ( { <EOL> <NUM_LIT:0> : "<STR_LIT>" , <EOL> <NUM_LIT:1> : "<STR_LIT>" , <EOL> <NUM_LIT:2> : "<STR_LIT>" , <EOL> <NUM_LIT:3> : "<STR_LIT>" , <EOL> <NUM_LIT:4> : "<STR_LIT>" , <EOL> <NUM_LIT:5> : "<STR_LIT>" , <EOL> <NUM_LIT:6> : "<STR_LIT>" , <EOL> <NUM_LIT:7> : "<STR_LIT>" , <EOL> <NUM_LIT:8> : "<STR_LIT>" , <EOL> <NUM_LIT:9> : "<STR_LIT>" , <EOL> } , <NUM_LIT:9> ) <EOL> _TYPES = _BuildTagLookupTable ( { <EOL> <NUM_LIT:0> : ProtocolBuffer . Encoder . NUMERIC , <EOL> <NUM_LIT:1> : ProtocolBuffer . Encoder . NUMERIC , <EOL> <NUM_LIT:2> : ProtocolBuffer . Encoder . STRING , <EOL> <NUM_LIT:3> : ProtocolBuffer . Encoder . STARTGROUP , <EOL> <NUM_LIT:4> : ProtocolBuffer . Encoder . STRING , <EOL> <NUM_LIT:5> : ProtocolBuffer . Encoder . STRING , <EOL> <NUM_LIT:6> : ProtocolBuffer . Encoder . STRING , <EOL> <NUM_LIT:7> : ProtocolBuffer . Encoder . NUMERIC , <EOL> <NUM_LIT:8> : ProtocolBuffer . Encoder . DOUBLE , <EOL> <NUM_LIT:9> : ProtocolBuffer . Encoder . NUMERIC , <EOL> } , <NUM_LIT:9> , ProtocolBuffer . Encoder . MAX_TYPE ) <EOL> _STYLE = """<STR_LIT>""" <EOL> _STYLE_CONTENT_TYPE = """<STR_LIT>""" <EOL> _PROTO_DESCRIPTOR_NAME = '<STR_LIT>' <EOL> class URLFetchResponse_Header ( ProtocolBuffer . ProtocolMessage ) : <EOL> has_key_ = <NUM_LIT:0> <EOL> key_ = "<STR_LIT>" <EOL> has_value_ = <NUM_LIT:0> <EOL> value_ = "<STR_LIT>" <EOL> def __init__ ( self , contents = None ) : <EOL> if contents is not None : self . MergeFromString ( contents ) <EOL> def key ( self ) : return self . key_ <EOL> def set_key ( self , x ) : <EOL> self . has_key_ = <NUM_LIT:1> <EOL> self . key_ = x <EOL> def clear_key ( self ) : <EOL> if self . has_key_ : <EOL> self . has_key_ = <NUM_LIT:0> <EOL> self . key_ = "<STR_LIT>" <EOL> def has_key ( self ) : return self . has_key_ <EOL> def value ( self ) : return self . value_ <EOL> def set_value ( self , x ) : <EOL> self . has_value_ = <NUM_LIT:1> <EOL> self . value_ = x <EOL> def clear_value ( self ) : <EOL> if self . has_value_ : <EOL> self . has_value_ = <NUM_LIT:0> <EOL> self . value_ = "<STR_LIT>" <EOL> def has_value ( self ) : return self . has_value_ <EOL> def MergeFrom ( self , x ) : <EOL> assert x is not self <EOL> if ( x . has_key ( ) ) : self . set_key ( x . key ( ) ) <EOL> if ( x . has_value ( ) ) : self . set_value ( x . value ( ) ) <EOL> def Equals ( self , x ) : <EOL> if x is self : return <NUM_LIT:1> <EOL> if self . has_key_ != x . has_key_ : return <NUM_LIT:0> <EOL> if self . has_key_ and self . key_ != x . key_ : return <NUM_LIT:0> <EOL> if self . has_value_ != x . has_value_ : return <NUM_LIT:0> <EOL> if self . has_value_ and self . value_ != x . value_ : return <NUM_LIT:0> <EOL> return <NUM_LIT:1> <EOL> def IsInitialized ( self , debug_strs = None ) : <EOL> initialized = <NUM_LIT:1> <EOL> if ( not self . has_key_ ) : <EOL> initialized = <NUM_LIT:0> <EOL> if debug_strs is not None : <EOL> debug_strs . append ( '<STR_LIT>' ) <EOL> if ( not self . has_value_ ) : <EOL> initialized = <NUM_LIT:0> <EOL> if debug_strs is not None : <EOL> debug_strs . append ( '<STR_LIT>' ) <EOL> return initialized <EOL> def ByteSize ( self ) : <EOL> n = <NUM_LIT:0> <EOL> n += self . lengthString ( len ( self . key_ ) ) <EOL> n += self . lengthString ( len ( self . value_ ) ) <EOL> return n + <NUM_LIT:2> <EOL> def ByteSizePartial ( self ) : <EOL> n = <NUM_LIT:0> <EOL> if ( self . has_key_ ) : <EOL> n += <NUM_LIT:1> <EOL> n += self . lengthString ( len ( self . key_ ) ) <EOL> if ( self . has_value_ ) : <EOL> n += <NUM_LIT:1> <EOL> n += self . lengthString ( len ( self . value_ ) ) <EOL> return n <EOL> def Clear ( self ) : <EOL> self . clear_key ( ) <EOL> self . clear_value ( ) <EOL> def OutputUnchecked ( self , out ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putPrefixedString ( self . key_ ) <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putPrefixedString ( self . value_ ) <EOL> def OutputPartial ( self , out ) : <EOL> if ( self . has_key_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putPrefixedString ( self . key_ ) <EOL> if ( self . has_value_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putPrefixedString ( self . value_ ) <EOL> def TryMerge ( self , d ) : <EOL> while <NUM_LIT:1> : <EOL> tt = d . getVarInt32 ( ) <EOL> if tt == <NUM_LIT> : break <EOL> if tt == <NUM_LIT> : <EOL> self . set_key ( d . getPrefixedString ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . set_value ( d . getPrefixedString ( ) ) <EOL> continue <EOL> if ( tt == <NUM_LIT:0> ) : raise ProtocolBuffer . ProtocolBufferDecodeError <EOL> d . skipData ( tt ) <EOL> def __str__ ( self , prefix = "<STR_LIT>" , printElemNumber = <NUM_LIT:0> ) : <EOL> res = "<STR_LIT>" <EOL> if self . has_key_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatString ( self . key_ ) ) <EOL> if self . has_value_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatString ( self . value_ ) ) <EOL> return res <EOL> class URLFetchResponse ( ProtocolBuffer . ProtocolMessage ) : <EOL> has_content_ = <NUM_LIT:0> <EOL> content_ = "<STR_LIT>" <EOL> has_statuscode_ = <NUM_LIT:0> <EOL> statuscode_ = <NUM_LIT:0> <EOL> has_contentwastruncated_ = <NUM_LIT:0> <EOL> contentwastruncated_ = <NUM_LIT:0> <EOL> has_externalbytessent_ = <NUM_LIT:0> <EOL> externalbytessent_ = <NUM_LIT:0> <EOL> has_externalbytesreceived_ = <NUM_LIT:0> <EOL> externalbytesreceived_ = <NUM_LIT:0> <EOL> has_finalurl_ = <NUM_LIT:0> <EOL> finalurl_ = "<STR_LIT>" <EOL> has_apicpumilliseconds_ = <NUM_LIT:0> <EOL> apicpumilliseconds_ = <NUM_LIT:0> <EOL> has_apibytessent_ = <NUM_LIT:0> <EOL> apibytessent_ = <NUM_LIT:0> <EOL> has_apibytesreceived_ = <NUM_LIT:0> <EOL> apibytesreceived_ = <NUM_LIT:0> <EOL> def __init__ ( self , contents = None ) : <EOL> self . header_ = [ ] <EOL> if contents is not None : self . MergeFromString ( contents ) <EOL> def content ( self ) : return self . content_ <EOL> def set_content ( self , x ) : <EOL> self . has_content_ = <NUM_LIT:1> <EOL> self . content_ = x <EOL> def clear_content ( self ) : <EOL> if self . has_content_ : <EOL> self . has_content_ = <NUM_LIT:0> <EOL> self . content_ = "<STR_LIT>" <EOL> def has_content ( self ) : return self . has_content_ <EOL> def statuscode ( self ) : return self . statuscode_ <EOL> def set_statuscode ( self , x ) : <EOL> self . has_statuscode_ = <NUM_LIT:1> <EOL> self . statuscode_ = x <EOL> def clear_statuscode ( self ) : <EOL> if self . has_statuscode_ : <EOL> self . has_statuscode_ = <NUM_LIT:0> <EOL> self . statuscode_ = <NUM_LIT:0> <EOL> def has_statuscode ( self ) : return self . has_statuscode_ <EOL> def header_size ( self ) : return len ( self . header_ ) <EOL> def header_list ( self ) : return self . header_ <EOL> def header ( self , i ) : <EOL> return self . header_ [ i ] <EOL> def mutable_header ( self , i ) : <EOL> return self . header_ [ i ] <EOL> def add_header ( self ) : <EOL> x = URLFetchResponse_Header ( ) <EOL> self . header_ . append ( x ) <EOL> return x <EOL> def clear_header ( self ) : <EOL> self . header_ = [ ] <EOL> def contentwastruncated ( self ) : return self . contentwastruncated_ <EOL> def set_contentwastruncated ( self , x ) : <EOL> self . has_contentwastruncated_ = <NUM_LIT:1> <EOL> self . contentwastruncated_ = x <EOL> def clear_contentwastruncated ( self ) : <EOL> if self . has_contentwastruncated_ : <EOL> self . has_contentwastruncated_ = <NUM_LIT:0> <EOL> self . contentwastruncated_ = <NUM_LIT:0> <EOL> def has_contentwastruncated ( self ) : return self . has_contentwastruncated_ <EOL> def externalbytessent ( self ) : return self . externalbytessent_ <EOL> def set_externalbytessent ( self , x ) : <EOL> self . has_externalbytessent_ = <NUM_LIT:1> <EOL> self . externalbytessent_ = x <EOL> def clear_externalbytessent ( self ) : <EOL> if self . has_externalbytessent_ : <EOL> self . has_externalbytessent_ = <NUM_LIT:0> <EOL> self . externalbytessent_ = <NUM_LIT:0> <EOL> def has_externalbytessent ( self ) : return self . has_externalbytessent_ <EOL> def externalbytesreceived ( self ) : return self . externalbytesreceived_ <EOL> def set_externalbytesreceived ( self , x ) : <EOL> self . has_externalbytesreceived_ = <NUM_LIT:1> <EOL> self . externalbytesreceived_ = x <EOL> def clear_externalbytesreceived ( self ) : <EOL> if self . has_externalbytesreceived_ : <EOL> self . has_externalbytesreceived_ = <NUM_LIT:0> <EOL> self . externalbytesreceived_ = <NUM_LIT:0> <EOL> def has_externalbytesreceived ( self ) : return self . has_externalbytesreceived_ <EOL> def finalurl ( self ) : return self . finalurl_ <EOL> def set_finalurl ( self , x ) : <EOL> self . has_finalurl_ = <NUM_LIT:1> <EOL> self . finalurl_ = x <EOL> def clear_finalurl ( self ) : <EOL> if self . has_finalurl_ : <EOL> self . has_finalurl_ = <NUM_LIT:0> <EOL> self . finalurl_ = "<STR_LIT>" <EOL> def has_finalurl ( self ) : return self . has_finalurl_ <EOL> def apicpumilliseconds ( self ) : return self . apicpumilliseconds_ <EOL> def set_apicpumilliseconds ( self , x ) : <EOL> self . has_apicpumilliseconds_ = <NUM_LIT:1> <EOL> self . apicpumilliseconds_ = x <EOL> def clear_apicpumilliseconds ( self ) : <EOL> if self . has_apicpumilliseconds_ : <EOL> self . has_apicpumilliseconds_ = <NUM_LIT:0> <EOL> self . apicpumilliseconds_ = <NUM_LIT:0> <EOL> def has_apicpumilliseconds ( self ) : return self . has_apicpumilliseconds_ <EOL> def apibytessent ( self ) : return self . apibytessent_ <EOL> def set_apibytessent ( self , x ) : <EOL> self . has_apibytessent_ = <NUM_LIT:1> <EOL> self . apibytessent_ = x <EOL> def clear_apibytessent ( self ) : <EOL> if self . has_apibytessent_ : <EOL> self . has_apibytessent_ = <NUM_LIT:0> <EOL> self . apibytessent_ = <NUM_LIT:0> <EOL> def has_apibytessent ( self ) : return self . has_apibytessent_ <EOL> def apibytesreceived ( self ) : return self . apibytesreceived_ <EOL> def set_apibytesreceived ( self , x ) : <EOL> self . has_apibytesreceived_ = <NUM_LIT:1> <EOL> self . apibytesreceived_ = x <EOL> def clear_apibytesreceived ( self ) : <EOL> if self . has_apibytesreceived_ : <EOL> self . has_apibytesreceived_ = <NUM_LIT:0> <EOL> self . apibytesreceived_ = <NUM_LIT:0> <EOL> def has_apibytesreceived ( self ) : return self . has_apibytesreceived_ <EOL> def MergeFrom ( self , x ) : <EOL> assert x is not self <EOL> if ( x . has_content ( ) ) : self . set_content ( x . content ( ) ) <EOL> if ( x . has_statuscode ( ) ) : self . set_statuscode ( x . statuscode ( ) ) <EOL> for i in xrange ( x . header_size ( ) ) : self . add_header ( ) . CopyFrom ( x . header ( i ) ) <EOL> if ( x . has_contentwastruncated ( ) ) : self . set_contentwastruncated ( x . contentwastruncated ( ) ) <EOL> if ( x . has_externalbytessent ( ) ) : self . set_externalbytessent ( x . externalbytessent ( ) ) <EOL> if ( x . has_externalbytesreceived ( ) ) : self . set_externalbytesreceived ( x . externalbytesreceived ( ) ) <EOL> if ( x . has_finalurl ( ) ) : self . set_finalurl ( x . finalurl ( ) ) <EOL> if ( x . has_apicpumilliseconds ( ) ) : self . set_apicpumilliseconds ( x . apicpumilliseconds ( ) ) <EOL> if ( x . has_apibytessent ( ) ) : self . set_apibytessent ( x . apibytessent ( ) ) <EOL> if ( x . has_apibytesreceived ( ) ) : self . set_apibytesreceived ( x . apibytesreceived ( ) ) <EOL> def Equals ( self , x ) : <EOL> if x is self : return <NUM_LIT:1> <EOL> if self . has_content_ != x . has_content_ : return <NUM_LIT:0> <EOL> if self . has_content_ and self . content_ != x . content_ : return <NUM_LIT:0> <EOL> if self . has_statuscode_ != x . has_statuscode_ : return <NUM_LIT:0> <EOL> if self . has_statuscode_ and self . statuscode_ != x . statuscode_ : return <NUM_LIT:0> <EOL> if len ( self . header_ ) != len ( x . header_ ) : return <NUM_LIT:0> <EOL> for e1 , e2 in zip ( self . header_ , x . header_ ) : <EOL> if e1 != e2 : return <NUM_LIT:0> <EOL> if self . has_contentwastruncated_ != x . has_contentwastruncated_ : return <NUM_LIT:0> <EOL> if self . has_contentwastruncated_ and self . contentwastruncated_ != x . contentwastruncated_ : return <NUM_LIT:0> <EOL> if self . has_externalbytessent_ != x . has_externalbytessent_ : return <NUM_LIT:0> <EOL> if self . has_externalbytessent_ and self . externalbytessent_ != x . externalbytessent_ : return <NUM_LIT:0> <EOL> if self . has_externalbytesreceived_ != x . has_externalbytesreceived_ : return <NUM_LIT:0> <EOL> if self . has_externalbytesreceived_ and self . externalbytesreceived_ != x . externalbytesreceived_ : return <NUM_LIT:0> <EOL> if self . has_finalurl_ != x . has_finalurl_ : return <NUM_LIT:0> <EOL> if self . has_finalurl_ and self . finalurl_ != x . finalurl_ : return <NUM_LIT:0> <EOL> if self . has_apicpumilliseconds_ != x . has_apicpumilliseconds_ : return <NUM_LIT:0> <EOL> if self . has_apicpumilliseconds_ and self . apicpumilliseconds_ != x . apicpumilliseconds_ : return <NUM_LIT:0> <EOL> if self . has_apibytessent_ != x . has_apibytessent_ : return <NUM_LIT:0> <EOL> if self . has_apibytessent_ and self . apibytessent_ != x . apibytessent_ : return <NUM_LIT:0> <EOL> if self . has_apibytesreceived_ != x . has_apibytesreceived_ : return <NUM_LIT:0> <EOL> if self . has_apibytesreceived_ and self . apibytesreceived_ != x . apibytesreceived_ : return <NUM_LIT:0> <EOL> return <NUM_LIT:1> <EOL> def IsInitialized ( self , debug_strs = None ) : <EOL> initialized = <NUM_LIT:1> <EOL> if ( not self . has_statuscode_ ) : <EOL> initialized = <NUM_LIT:0> <EOL> if debug_strs is not None : <EOL> debug_strs . append ( '<STR_LIT>' ) <EOL> for p in self . header_ : <EOL> if not p . IsInitialized ( debug_strs ) : initialized = <NUM_LIT:0> <EOL> return initialized <EOL> def ByteSize ( self ) : <EOL> n = <NUM_LIT:0> <EOL> if ( self . has_content_ ) : n += <NUM_LIT:1> + self . lengthString ( len ( self . content_ ) ) <EOL> n += self . lengthVarInt64 ( self . statuscode_ ) <EOL> n += <NUM_LIT:2> * len ( self . header_ ) <EOL> for i in xrange ( len ( self . header_ ) ) : n += self . header_ [ i ] . ByteSize ( ) <EOL> if ( self . has_contentwastruncated_ ) : n += <NUM_LIT:2> <EOL> if ( self . has_externalbytessent_ ) : n += <NUM_LIT:1> + self . lengthVarInt64 ( self . externalbytessent_ ) <EOL> if ( self . has_externalbytesreceived_ ) : n += <NUM_LIT:1> + self . lengthVarInt64 ( self . externalbytesreceived_ ) <EOL> if ( self . has_finalurl_ ) : n += <NUM_LIT:1> + self . lengthString ( len ( self . finalurl_ ) ) <EOL> if ( self . has_apicpumilliseconds_ ) : n += <NUM_LIT:1> + self . lengthVarInt64 ( self . apicpumilliseconds_ ) <EOL> if ( self . has_apibytessent_ ) : n += <NUM_LIT:1> + self . lengthVarInt64 ( self . apibytessent_ ) <EOL> if ( self . has_apibytesreceived_ ) : n += <NUM_LIT:1> + self . lengthVarInt64 ( self . apibytesreceived_ ) <EOL> return n + <NUM_LIT:1> <EOL> def ByteSizePartial ( self ) : <EOL> n = <NUM_LIT:0> <EOL> if ( self . has_content_ ) : n += <NUM_LIT:1> + self . lengthString ( len ( self . content_ ) ) <EOL> if ( self . has_statuscode_ ) : <EOL> n += <NUM_LIT:1> <EOL> n += self . lengthVarInt64 ( self . statuscode_ ) <EOL> n += <NUM_LIT:2> * len ( self . header_ ) <EOL> for i in xrange ( len ( self . header_ ) ) : n += self . header_ [ i ] . ByteSizePartial ( ) <EOL> if ( self . has_contentwastruncated_ ) : n += <NUM_LIT:2> <EOL> if ( self . has_externalbytessent_ ) : n += <NUM_LIT:1> + self . lengthVarInt64 ( self . externalbytessent_ ) <EOL> if ( self . has_externalbytesreceived_ ) : n += <NUM_LIT:1> + self . lengthVarInt64 ( self . externalbytesreceived_ ) <EOL> if ( self . has_finalurl_ ) : n += <NUM_LIT:1> + self . lengthString ( len ( self . finalurl_ ) ) <EOL> if ( self . has_apicpumilliseconds_ ) : n += <NUM_LIT:1> + self . lengthVarInt64 ( self . apicpumilliseconds_ ) <EOL> if ( self . has_apibytessent_ ) : n += <NUM_LIT:1> + self . lengthVarInt64 ( self . apibytessent_ ) <EOL> if ( self . has_apibytesreceived_ ) : n += <NUM_LIT:1> + self . lengthVarInt64 ( self . apibytesreceived_ ) <EOL> return n <EOL> def Clear ( self ) : <EOL> self . clear_content ( ) <EOL> self . clear_statuscode ( ) <EOL> self . clear_header ( ) <EOL> self . clear_contentwastruncated ( ) <EOL> self . clear_externalbytessent ( ) <EOL> self . clear_externalbytesreceived ( ) <EOL> self . clear_finalurl ( ) <EOL> self . clear_apicpumilliseconds ( ) <EOL> self . clear_apibytessent ( ) <EOL> self . clear_apibytesreceived ( ) <EOL> def OutputUnchecked ( self , out ) : <EOL> if ( self . has_content_ ) : <EOL> out . putVarInt32 ( <NUM_LIT:10> ) <EOL> out . putPrefixedString ( self . content_ ) <EOL> out . putVarInt32 ( <NUM_LIT:16> ) <EOL> out . putVarInt32 ( self . statuscode_ ) <EOL> for i in xrange ( len ( self . header_ ) ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> self . header_ [ i ] . OutputUnchecked ( out ) <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> if ( self . has_contentwastruncated_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putBoolean ( self . contentwastruncated_ ) <EOL> if ( self . has_externalbytessent_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putVarInt64 ( self . externalbytessent_ ) <EOL> if ( self . has_externalbytesreceived_ ) : <EOL> out . putVarInt32 ( <NUM_LIT:64> ) <EOL> out . putVarInt64 ( self . externalbytesreceived_ ) <EOL> if ( self . has_finalurl_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putPrefixedString ( self . finalurl_ ) <EOL> if ( self . has_apicpumilliseconds_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putVarInt64 ( self . apicpumilliseconds_ ) <EOL> if ( self . has_apibytessent_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putVarInt64 ( self . apibytessent_ ) <EOL> if ( self . has_apibytesreceived_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putVarInt64 ( self . apibytesreceived_ ) <EOL> def OutputPartial ( self , out ) : <EOL> if ( self . has_content_ ) : <EOL> out . putVarInt32 ( <NUM_LIT:10> ) <EOL> out . putPrefixedString ( self . content_ ) <EOL> if ( self . has_statuscode_ ) : <EOL> out . putVarInt32 ( <NUM_LIT:16> ) <EOL> out . putVarInt32 ( self . statuscode_ ) <EOL> for i in xrange ( len ( self . header_ ) ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> self . header_ [ i ] . OutputPartial ( out ) <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> if ( self . has_contentwastruncated_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putBoolean ( self . contentwastruncated_ ) <EOL> if ( self . has_externalbytessent_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putVarInt64 ( self . externalbytessent_ ) <EOL> if ( self . has_externalbytesreceived_ ) : <EOL> out . putVarInt32 ( <NUM_LIT:64> ) <EOL> out . putVarInt64 ( self . externalbytesreceived_ ) <EOL> if ( self . has_finalurl_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putPrefixedString ( self . finalurl_ ) <EOL> if ( self . has_apicpumilliseconds_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putVarInt64 ( self . apicpumilliseconds_ ) <EOL> if ( self . has_apibytessent_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putVarInt64 ( self . apibytessent_ ) <EOL> if ( self . has_apibytesreceived_ ) : <EOL> out . putVarInt32 ( <NUM_LIT> ) <EOL> out . putVarInt64 ( self . apibytesreceived_ ) <EOL> def TryMerge ( self , d ) : <EOL> while d . avail ( ) > <NUM_LIT:0> : <EOL> tt = d . getVarInt32 ( ) <EOL> if tt == <NUM_LIT:10> : <EOL> self . set_content ( d . getPrefixedString ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT:16> : <EOL> self . set_statuscode ( d . getVarInt32 ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . add_header ( ) . TryMerge ( d ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . set_contentwastruncated ( d . getBoolean ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . set_externalbytessent ( d . getVarInt64 ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT:64> : <EOL> self . set_externalbytesreceived ( d . getVarInt64 ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . set_finalurl ( d . getPrefixedString ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . set_apicpumilliseconds ( d . getVarInt64 ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . set_apibytessent ( d . getVarInt64 ( ) ) <EOL> continue <EOL> if tt == <NUM_LIT> : <EOL> self . set_apibytesreceived ( d . getVarInt64 ( ) ) <EOL> continue <EOL> if ( tt == <NUM_LIT:0> ) : raise ProtocolBuffer . ProtocolBufferDecodeError <EOL> d . skipData ( tt ) <EOL> def __str__ ( self , prefix = "<STR_LIT>" , printElemNumber = <NUM_LIT:0> ) : <EOL> res = "<STR_LIT>" <EOL> if self . has_content_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatString ( self . content_ ) ) <EOL> if self . has_statuscode_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatInt32 ( self . statuscode_ ) ) <EOL> cnt = <NUM_LIT:0> <EOL> for e in self . header_ : <EOL> elm = "<STR_LIT>" <EOL> if printElemNumber : elm = "<STR_LIT>" % cnt <EOL> res += prefix + ( "<STR_LIT>" % elm ) <EOL> res += e . __str__ ( prefix + "<STR_LIT:U+0020>" , printElemNumber ) <EOL> res += prefix + "<STR_LIT>" <EOL> cnt += <NUM_LIT:1> <EOL> if self . has_contentwastruncated_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatBool ( self . contentwastruncated_ ) ) <EOL> if self . has_externalbytessent_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatInt64 ( self . externalbytessent_ ) ) <EOL> if self . has_externalbytesreceived_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatInt64 ( self . externalbytesreceived_ ) ) <EOL> if self . has_finalurl_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatString ( self . finalurl_ ) ) <EOL> if self . has_apicpumilliseconds_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatInt64 ( self . apicpumilliseconds_ ) ) <EOL> if self . has_apibytessent_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatInt64 ( self . apibytessent_ ) ) <EOL> if self . has_apibytesreceived_ : res += prefix + ( "<STR_LIT>" % self . DebugFormatInt64 ( self . apibytesreceived_ ) ) <EOL> return res <EOL> def _BuildTagLookupTable ( sparse , maxtag , default = None ) : <EOL> return tuple ( [ sparse . get ( i , default ) for i in xrange ( <NUM_LIT:0> , <NUM_LIT:1> + maxtag ) ] ) <EOL> kContent = <NUM_LIT:1> <EOL> kStatusCode = <NUM_LIT:2> <EOL> kHeaderGroup = <NUM_LIT:3> <EOL> kHeaderKey = <NUM_LIT:4> <EOL> kHeaderValue = <NUM_LIT:5> <EOL> kContentWasTruncated = <NUM_LIT:6> <EOL> kExternalBytesSent = <NUM_LIT:7> <EOL> kExternalBytesReceived = <NUM_LIT:8> <EOL> kFinalUrl = <NUM_LIT:9> <EOL> kApiCpuMilliseconds = <NUM_LIT:10> <EOL> kApiBytesSent = <NUM_LIT:11> <EOL> kApiBytesReceived = <NUM_LIT:12> <EOL> _TEXT = _BuildTagLookupTable ( { <EOL> <NUM_LIT:0> : "<STR_LIT>" , <EOL> <NUM_LIT:1> : "<STR_LIT>" , <EOL> <NUM_LIT:2> : "<STR_LIT>" , <EOL> <NUM_LIT:3> : "<STR_LIT>" , <EOL> <NUM_LIT:4> : "<STR_LIT>" , <EOL> <NUM_LIT:5> : "<STR_LIT>" , <EOL> <NUM_LIT:6> : "<STR_LIT>" , <EOL> <NUM_LIT:7> : "<STR_LIT>" , <EOL> <NUM_LIT:8> : "<STR_LIT>" , <EOL> <NUM_LIT:9> : "<STR_LIT>" , <EOL> <NUM_LIT:10> : "<STR_LIT>" , <EOL> <NUM_LIT:11> : "<STR_LIT>" , <EOL> <NUM_LIT:12> : "<STR_LIT>" , <EOL> } , <NUM_LIT:12> ) <EOL> _TYPES = _BuildTagLookupTable ( { <EOL> <NUM_LIT:0> : ProtocolBuffer . Encoder . NUMERIC , <EOL> <NUM_LIT:1> : ProtocolBuffer . Encoder . STRING , <EOL> <NUM_LIT:2> : ProtocolBuffer . Encoder . NUMERIC , <EOL> <NUM_LIT:3> : ProtocolBuffer . Encoder . STARTGROUP , <EOL> <NUM_LIT:4> : ProtocolBuffer . Encoder . STRING , <EOL> <NUM_LIT:5> : ProtocolBuffer . Encoder . STRING , <EOL> <NUM_LIT:6> : ProtocolBuffer . Encoder . NUMERIC , <EOL> <NUM_LIT:7> : ProtocolBuffer . Encoder . NUMERIC , <EOL> <NUM_LIT:8> : ProtocolBuffer . Encoder . NUMERIC , <EOL> <NUM_LIT:9> : ProtocolBuffer . Encoder . STRING , <EOL> <NUM_LIT:10> : ProtocolBuffer . Encoder . NUMERIC , <EOL> <NUM_LIT:11> : ProtocolBuffer . Encoder . NUMERIC , <EOL> <NUM_LIT:12> : ProtocolBuffer . Encoder . NUMERIC , <EOL> } , <NUM_LIT:12> , ProtocolBuffer . Encoder . MAX_TYPE ) <EOL> _STYLE = """<STR_LIT>""" <EOL> _STYLE_CONTENT_TYPE = """<STR_LIT>""" <EOL> _PROTO_DESCRIPTOR_NAME = '<STR_LIT>' <EOL> if _extension_runtime : <EOL> pass <EOL> __all__ = [ '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' ] </s>
