BasePartial.java
3.81 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
package org.joda.time.base;
import java.io.Serializable;
import java.util.Locale;
import org.joda.time.Chronology;
import org.joda.time.DateTimeField;
import org.joda.time.DateTimeUtils;
import org.joda.time.ReadablePartial;
import org.joda.time.convert.ConverterManager;
import org.joda.time.convert.PartialConverter;
import org.joda.time.format.DateTimeFormat;
import org.joda.time.format.DateTimeFormatter;
public abstract class BasePartial
extends AbstractPartial
implements Serializable, ReadablePartial
{
private static final long serialVersionUID = 2353678632973660L;
private final Chronology a;
private final int[] b;
protected BasePartial()
{
this(DateTimeUtils.currentTimeMillis(), null);
}
protected BasePartial(long paramLong)
{
this(paramLong, null);
}
protected BasePartial(long paramLong, Chronology paramChronology)
{
paramChronology = DateTimeUtils.getChronology(paramChronology);
this.a = paramChronology.withUTC();
this.b = paramChronology.get(this, paramLong);
}
protected BasePartial(Object paramObject, Chronology paramChronology)
{
PartialConverter localPartialConverter = ConverterManager.getInstance().getPartialConverter(paramObject);
paramChronology = DateTimeUtils.getChronology(localPartialConverter.getChronology(paramObject, paramChronology));
this.a = paramChronology.withUTC();
this.b = localPartialConverter.getPartialValues(this, paramObject, paramChronology);
}
protected BasePartial(Object paramObject, Chronology paramChronology, DateTimeFormatter paramDateTimeFormatter)
{
PartialConverter localPartialConverter = ConverterManager.getInstance().getPartialConverter(paramObject);
paramChronology = DateTimeUtils.getChronology(localPartialConverter.getChronology(paramObject, paramChronology));
this.a = paramChronology.withUTC();
this.b = localPartialConverter.getPartialValues(this, paramObject, paramChronology, paramDateTimeFormatter);
}
protected BasePartial(Chronology paramChronology)
{
this(DateTimeUtils.currentTimeMillis(), paramChronology);
}
protected BasePartial(BasePartial paramBasePartial, Chronology paramChronology)
{
this.a = paramChronology.withUTC();
this.b = paramBasePartial.b;
}
protected BasePartial(BasePartial paramBasePartial, int[] paramArrayOfInt)
{
this.a = paramBasePartial.a;
this.b = paramArrayOfInt;
}
protected BasePartial(int[] paramArrayOfInt, Chronology paramChronology)
{
paramChronology = DateTimeUtils.getChronology(paramChronology);
this.a = paramChronology.withUTC();
paramChronology.validate(this, paramArrayOfInt);
this.b = paramArrayOfInt;
}
public Chronology getChronology()
{
return this.a;
}
public int getValue(int paramInt)
{
return this.b[paramInt];
}
public int[] getValues()
{
return (int[])this.b.clone();
}
protected void setValue(int paramInt1, int paramInt2)
{
System.arraycopy(getField(paramInt1).set(this, paramInt1, this.b, paramInt2), 0, this.b, 0, this.b.length);
}
protected void setValues(int[] paramArrayOfInt)
{
getChronology().validate(this, paramArrayOfInt);
System.arraycopy(paramArrayOfInt, 0, this.b, 0, this.b.length);
}
public String toString(String paramString)
{
if (paramString == null) {
return toString();
}
return DateTimeFormat.forPattern(paramString).print(this);
}
public String toString(String paramString, Locale paramLocale)
throws IllegalArgumentException
{
if (paramString == null) {
return toString();
}
return DateTimeFormat.forPattern(paramString).withLocale(paramLocale).print(this);
}
}
/* Location: /home/merong/decompile/hackery-dex2jar.jar!/org/joda/time/base/BasePartial.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/