123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833 |
- .class final Lokhttp3/internal/http2/Hpack;
- .super Ljava/lang/Object;
- .source ""
- # annotations
- .annotation system Ldalvik/annotation/MemberClasses;
- value = {
- Lokhttp3/internal/http2/Hpack$Writer;,
- Lokhttp3/internal/http2/Hpack$Reader;
- }
- .end annotation
- # static fields
- .field static final NAME_TO_FIRST_INDEX:Ljava/util/Map;
- .annotation system Ldalvik/annotation/Signature;
- value = {
- "Ljava/util/Map<",
- "Lokio/ByteString;",
- "Ljava/lang/Integer;",
- ">;"
- }
- .end annotation
- .end field
- .field private static final PREFIX_4_BITS:I = 0xf
- .field private static final PREFIX_5_BITS:I = 0x1f
- .field private static final PREFIX_6_BITS:I = 0x3f
- .field private static final PREFIX_7_BITS:I = 0x7f
- .field static final STATIC_HEADER_TABLE:[Lokhttp3/internal/http2/Header;
- # direct methods
- .method static constructor <clinit>()V
- .locals 5
- const/16 v0, 0x3d
- new-array v0, v0, [Lokhttp3/internal/http2/Header;
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->TARGET_AUTHORITY:Lokio/ByteString;
- const-string v3, ""
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/4 v2, 0x0
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->TARGET_METHOD:Lokio/ByteString;
- const-string v4, "GET"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/4 v2, 0x1
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->TARGET_METHOD:Lokio/ByteString;
- const-string v4, "POST"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/4 v2, 0x2
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->TARGET_PATH:Lokio/ByteString;
- const-string v4, "/"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/4 v2, 0x3
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->TARGET_PATH:Lokio/ByteString;
- const-string v4, "/index.html"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/4 v2, 0x4
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->TARGET_SCHEME:Lokio/ByteString;
- const-string v4, "http"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/4 v2, 0x5
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->TARGET_SCHEME:Lokio/ByteString;
- const-string v4, "https"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/4 v2, 0x6
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->RESPONSE_STATUS:Lokio/ByteString;
- const-string v4, "200"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/4 v2, 0x7
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->RESPONSE_STATUS:Lokio/ByteString;
- const-string v4, "204"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/16 v2, 0x8
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->RESPONSE_STATUS:Lokio/ByteString;
- const-string v4, "206"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/16 v2, 0x9
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->RESPONSE_STATUS:Lokio/ByteString;
- const-string v4, "304"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/16 v2, 0xa
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->RESPONSE_STATUS:Lokio/ByteString;
- const-string v4, "400"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/16 v2, 0xb
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->RESPONSE_STATUS:Lokio/ByteString;
- const-string v4, "404"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/16 v2, 0xc
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- sget-object v2, Lokhttp3/internal/http2/Header;->RESPONSE_STATUS:Lokio/ByteString;
- const-string v4, "500"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Lokio/ByteString;Ljava/lang/String;)V
- const/16 v2, 0xd
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "accept-charset"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0xe
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "accept-encoding"
- const-string v4, "gzip, deflate"
- invoke-direct {v1, v2, v4}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0xf
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "accept-language"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x10
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "accept-ranges"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x11
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "accept"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x12
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "access-control-allow-origin"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x13
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "age"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x14
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "allow"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x15
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "authorization"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x16
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "cache-control"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x17
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "content-disposition"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x18
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "content-encoding"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x19
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "content-language"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x1a
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "content-length"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x1b
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "content-location"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x1c
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "content-range"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x1d
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "content-type"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x1e
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "cookie"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x1f
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "date"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x20
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "etag"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x21
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "expect"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x22
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "expires"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x23
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "from"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x24
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "host"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x25
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "if-match"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x26
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "if-modified-since"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x27
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "if-none-match"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x28
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "if-range"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x29
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "if-unmodified-since"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x2a
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "last-modified"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x2b
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "link"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x2c
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "location"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x2d
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "max-forwards"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x2e
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "proxy-authenticate"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x2f
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "proxy-authorization"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x30
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "range"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x31
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "referer"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x32
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "refresh"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x33
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "retry-after"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x34
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "server"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x35
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "set-cookie"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x36
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "strict-transport-security"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x37
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "transfer-encoding"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x38
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "user-agent"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x39
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "vary"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x3a
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "via"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x3b
- aput-object v1, v0, v2
- new-instance v1, Lokhttp3/internal/http2/Header;
- const-string v2, "www-authenticate"
- invoke-direct {v1, v2, v3}, Lokhttp3/internal/http2/Header;-><init>(Ljava/lang/String;Ljava/lang/String;)V
- const/16 v2, 0x3c
- aput-object v1, v0, v2
- sput-object v0, Lokhttp3/internal/http2/Hpack;->STATIC_HEADER_TABLE:[Lokhttp3/internal/http2/Header;
- invoke-static {}, Lokhttp3/internal/http2/Hpack;->nameToFirstIndex()Ljava/util/Map;
- move-result-object v0
- sput-object v0, Lokhttp3/internal/http2/Hpack;->NAME_TO_FIRST_INDEX:Ljava/util/Map;
- return-void
- .end method
- .method private constructor <init>()V
- .locals 0
- invoke-direct {p0}, Ljava/lang/Object;-><init>()V
- return-void
- .end method
- .method static checkLowercase(Lokio/ByteString;)Lokio/ByteString;
- .locals 4
- .annotation system Ldalvik/annotation/Throws;
- value = {
- Ljava/io/IOException;
- }
- .end annotation
- invoke-virtual {p0}, Lokio/ByteString;->size()I
- move-result v0
- const/4 v1, 0x0
- :goto_0
- if-ge v1, v0, :cond_2
- invoke-virtual {p0, v1}, Lokio/ByteString;->getByte(I)B
- move-result v2
- const/16 v3, 0x41
- if-lt v2, v3, :cond_1
- const/16 v3, 0x5a
- if-le v2, v3, :cond_0
- goto :goto_1
- :cond_0
- new-instance v0, Ljava/io/IOException;
- new-instance v1, Ljava/lang/StringBuilder;
- invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V
- const-string v2, "PROTOCOL_ERROR response malformed: mixed case name: "
- invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
- invoke-virtual {p0}, Lokio/ByteString;->utf8()Ljava/lang/String;
- move-result-object p0
- invoke-virtual {v1, p0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
- invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
- move-result-object p0
- invoke-direct {v0, p0}, Ljava/io/IOException;-><init>(Ljava/lang/String;)V
- throw v0
- :cond_1
- :goto_1
- add-int/lit8 v1, v1, 0x1
- goto :goto_0
- :cond_2
- return-object p0
- .end method
- .method private static nameToFirstIndex()Ljava/util/Map;
- .locals 4
- .annotation system Ldalvik/annotation/Signature;
- value = {
- "()",
- "Ljava/util/Map<",
- "Lokio/ByteString;",
- "Ljava/lang/Integer;",
- ">;"
- }
- .end annotation
- new-instance v0, Ljava/util/LinkedHashMap;
- sget-object v1, Lokhttp3/internal/http2/Hpack;->STATIC_HEADER_TABLE:[Lokhttp3/internal/http2/Header;
- array-length v1, v1
- invoke-direct {v0, v1}, Ljava/util/LinkedHashMap;-><init>(I)V
- const/4 v1, 0x0
- :goto_0
- sget-object v2, Lokhttp3/internal/http2/Hpack;->STATIC_HEADER_TABLE:[Lokhttp3/internal/http2/Header;
- array-length v3, v2
- if-ge v1, v3, :cond_1
- aget-object v2, v2, v1
- iget-object v2, v2, Lokhttp3/internal/http2/Header;->name:Lokio/ByteString;
- invoke-interface {v0, v2}, Ljava/util/Map;->containsKey(Ljava/lang/Object;)Z
- move-result v2
- if-nez v2, :cond_0
- sget-object v2, Lokhttp3/internal/http2/Hpack;->STATIC_HEADER_TABLE:[Lokhttp3/internal/http2/Header;
- aget-object v2, v2, v1
- iget-object v2, v2, Lokhttp3/internal/http2/Header;->name:Lokio/ByteString;
- invoke-static {v1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
- move-result-object v3
- invoke-interface {v0, v2, v3}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
- :cond_0
- add-int/lit8 v1, v1, 0x1
- goto :goto_0
- :cond_1
- invoke-static {v0}, Ljava/util/Collections;->unmodifiableMap(Ljava/util/Map;)Ljava/util/Map;
- move-result-object v0
- return-object v0
- .end method
|