84 lines
1.9 KiB
Smali
84 lines
1.9 KiB
Smali
.class public Lcom/thoughtworks/xstream/converters/collections/CharArrayConverter;
|
|
.super Ljava/lang/Object;
|
|
.source "CharArrayConverter.java"
|
|
|
|
# interfaces
|
|
.implements Lcom/thoughtworks/xstream/converters/Converter;
|
|
|
|
|
|
# direct methods
|
|
.method public constructor <init>()V
|
|
.locals 0
|
|
|
|
.line 1
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public canConvert(Ljava/lang/Class;)Z
|
|
.locals 1
|
|
|
|
.line 1
|
|
invoke-virtual {p1}, Ljava/lang/Class;->isArray()Z
|
|
|
|
move-result v0
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
invoke-virtual {p1}, Ljava/lang/Class;->getComponentType()Ljava/lang/Class;
|
|
|
|
move-result-object p1
|
|
|
|
sget-object v0, Ljava/lang/Character;->TYPE:Ljava/lang/Class;
|
|
|
|
invoke-virtual {p1, v0}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
|
|
|
|
move-result p1
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
const/4 p1, 0x1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 p1, 0x0
|
|
|
|
:goto_0
|
|
return p1
|
|
.end method
|
|
|
|
.method public marshal(Ljava/lang/Object;Lcom/thoughtworks/xstream/io/HierarchicalStreamWriter;Lcom/thoughtworks/xstream/converters/MarshallingContext;)V
|
|
.locals 0
|
|
|
|
.line 1
|
|
check-cast p1, [C
|
|
|
|
.line 2
|
|
new-instance p3, Ljava/lang/String;
|
|
|
|
invoke-direct {p3, p1}, Ljava/lang/String;-><init>([C)V
|
|
|
|
invoke-interface {p2, p3}, Lcom/thoughtworks/xstream/io/HierarchicalStreamWriter;->setValue(Ljava/lang/String;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public unmarshal(Lcom/thoughtworks/xstream/io/HierarchicalStreamReader;Lcom/thoughtworks/xstream/converters/UnmarshallingContext;)Ljava/lang/Object;
|
|
.locals 0
|
|
|
|
.line 1
|
|
invoke-interface {p1}, Lcom/thoughtworks/xstream/io/HierarchicalStreamReader;->getValue()Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {p1}, Ljava/lang/String;->toCharArray()[C
|
|
|
|
move-result-object p1
|
|
|
|
return-object p1
|
|
.end method
|