| | | |
Offset 30, 177 lines modified | Offset 30, 14 lines modified |
| |
30 | ····.line·1 | 30 | ····.line·1 |
31 | ····invoke-direct·{p0},·Ljava/lang/Object;-><init>()V | 31 | ····invoke-direct·{p0},·Ljava/lang/Object;-><init>()V |
| |
32 | ····return-void | 32 | ····return-void |
33 | .end·method | 33 | .end·method |
| |
34 | .method·private·static·decode(C)I | |
35 | ····.locals·3 | |
| |
36 | ····const/16·v0,·0x30 | |
| |
37 | ····if-lt·p0,·v0,·:cond_0 | |
| |
38 | ····const/16·v1,·0x39 | |
| |
39 | ····if-gt·p0,·v1,·:cond_0 | |
| |
40 | ····sub-int/2addr·p0,·v0 | |
| |
41 | ····return·p0 | |
| |
42 | ····:cond_0 | |
43 | ····const/16·v0,·0x61 | |
| |
44 | ····if-lt·p0,·v0,·:cond_1 | |
| |
45 | ····const/16·v1,·0x66 | |
| |
46 | ····if-gt·p0,·v1,·:cond_1 | |
| |
47 | ····sub-int/2addr·p0,·v0 | |
| |
48 | ····add-int/lit8·p0,·p0,·0xa | |
| |
49 | ····return·p0 | |
| |
50 | ····.line·1 | |
51 | ····:cond_1 | |
52 | ····new-instance·v0,·Ljava/lang/IllegalArgumentException; | |
| |
53 | ····new-instance·v1,·Ljava/lang/StringBuilder; | |
| |
54 | ····invoke-direct·{v1},·Ljava/lang/StringBuilder;-><init>()V | |
| |
55 | ····const-string·v2,·"Illegal·hexadecimal·character:·" | |
| |
56 | ····invoke-virtual·{v1,·v2},·Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder; | |
| |
57 | ····invoke-virtual·{v1,·p0},·Ljava/lang/StringBuilder;->append(C)Ljava/lang/StringBuilder; | |
| |
58 | ····invoke-virtual·{v1},·Ljava/lang/StringBuilder;->toString()Ljava/lang/String; | |
| |
59 | ····move-result-object·p0 | |
| |
60 | ····invoke-direct·{v0,·p0},·Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V | |
| |
61 | ····throw·v0 | |
62 | .end·method | |
| |
63 | .method·public·static·fromString(Ljava/lang/String;)Lcom/google/common/hash/HashCode; | |
64 | ····.locals·5 | |
| |
65 | ····.line·1 | |
66 | ····invoke-virtual·{p0},·Ljava/lang/String;->length()I | |
| |
67 | ····move-result·v0 | |
| |
68 | ····const/4·v1,·0x1 | |
| |
69 | ····const/4·v2,·0x0 | |
| |
70 | ····const/4·v3,·0x2 | |
| |
71 | ····if-lt·v0,·v3,·:cond_0 | |
| |
72 | ····move·v0,·v1 | |
| |
73 | ····goto·:goto_0 | |
| |
74 | ····:cond_0 | |
75 | ····move·v0,·v2 | |
| |
76 | ····:goto_0 | |
77 | ····const-string·v4,·"input·string·(%s)·must·have·at·least·2·characters" | |
| |
78 | ····.line·2 | |
79 | ····invoke-static·{v0,·v4,·p0},·Lcom/google/common/base/Ascii;->checkArgument(ZLjava/lang/String;Ljava/lang/Object;)V | |
| |
80 | ····.line·3 | |
81 | ····invoke-virtual·{p0},·Ljava/lang/String;->length()I | |
| |
82 | ····move-result·v0 | |
| |
83 | ····rem-int/2addr·v0,·v3 | |
| |
84 | ····if-nez·v0,·:cond_1 | |
| |
85 | ····goto·:goto_1 | |
| |
86 | ····:cond_1 | |
87 | ····move·v1,·v2 | |
| |
88 | ····:goto_1 | |
89 | ····const-string·v0,·"input·string·(%s)·must·have·an·even·number·of·characters" | |
| |
90 | ····.line·4 | |
91 | ····invoke-static·{v1,·v0,·p0},·Lcom/google/common/base/Ascii;->checkArgument(ZLjava/lang/String;Ljava/lang/Object;)V | |
| |
92 | ····.line·5 | |
93 | ····invoke-virtual·{p0},·Ljava/lang/String;->length()I | |
| |
94 | ····move-result·v0 | |
| |
95 | ····div-int/2addr·v0,·v3 | |
| |
96 | ····new-array·v0,·v0,·[B | |
| |
97 | ····.line·6 | |
98 | ····:goto_2 | |
99 | ····invoke-virtual·{p0},·Ljava/lang/String;->length()I | |
| |
100 | ····move-result·v1 | |
| |
101 | ····if-ge·v2,·v1,·:cond_2 | |
| |
102 | ····.line·7 | |
103 | ····invoke-virtual·{p0,·v2},·Ljava/lang/String;->charAt(I)C | |
| |
104 | ····move-result·v1 | |
| |
105 | ····invoke-static·{v1},·Lcom/google/common/hash/HashCode;->decode(C)I | |
| |
106 | ····move-result·v1 | |
| |
107 | ····shl-int/lit8·v1,·v1,·0x4 | |
| |
108 | ····add-int/lit8·v3,·v2,·0x1 | |
| |
109 | ····.line·8 | |
110 | ····invoke-virtual·{p0,·v3},·Ljava/lang/String;->charAt(I)C | |
| |
111 | ····move-result·v3 | |
| |
112 | ····invoke-static·{v3},·Lcom/google/common/hash/HashCode;->decode(C)I | |
| |
113 | ····move-result·v3 | |
| |
114 | ····.line·9 | |
115 | ····div-int/lit8·v4,·v2,·0x2 | |
| |
116 | ····add-int/2addr·v1,·v3 | |
| |
117 | ····int-to-byte·v1,·v1 | |
| |
118 | ····aput-byte·v1,·v0,·v4 | |
| |
119 | ····add-int/lit8·v2,·v2,·0x2 | |
| |
120 | ····goto·:goto_2 | |
| |
121 | ····.line·10 | |
122 | ····:cond_2 | |
123 | ····new-instance·p0,·Lcom/google/common/hash/HashCode$BytesHashCode; | |
| |
124 | ····invoke-direct·{p0,·v0},·Lcom/google/common/hash/HashCode$BytesHashCode;-><init>([B)V | |
| |
125 | ····return-object·p0 | |
126 | .end·method | |
| |
| |
127 | #·virtual·methods | 34 | #·virtual·methods |
128 | .method·public·abstract·asBytes()[B | 35 | .method·public·abstract·asBytes()[B |
129 | .end·method | 36 | .end·method |
| |
130 | .method·public·abstract·asInt()I | 37 | .method·public·abstract·asInt()I |
131 | .end·method | 38 | .end·method |