正在查看: Tasker v6.5.11 应用的 lq.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: Tasker v6.5.11 应用的 lq.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package net.dinglisch.android.taskerm;
import android.content.Context;
import android.content.SharedPreferences;
import android.os.Bundle;
import com.joaomgcd.taskerm.structuredoutput.StructureType;
import hg.z1;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
public final class lq {
public static final a a = new a(null);
private static final lj.j<hk.k> b = lj.k.b(b.i);
private static final lj.j<hk.k> c = lj.k.b(c.i);
public static final class a {
static final class C0253a extends yj.q implements xj.a<SharedPreferences.Editor> {
final Context i;
C0253a(Context context) {
super(0);
this.i = context;
}
@Override
public final SharedPreferences.Editor invoke() {
return kq.u0(this.i).edit();
}
}
static final class b extends yj.q implements xj.l<String, String> {
final Bundle i;
final Context q;
b(Bundle bundle, Context context) {
super(1);
this.i = bundle;
this.q = context;
}
@Override
public final String invoke(String str) {
yj.p.i(str, "it");
return kq.W0(str) ? lq.a.C(this.i, str) : kq.B0(this.q, str);
}
}
static final class c extends yj.q implements xj.a<com.joaomgcd.taskerm.util.j7> {
final String i;
c(String str) {
super(0);
this.i = str;
}
@Override
public final com.joaomgcd.taskerm.util.j7 invoke() {
return new wf.l(this.i);
}
}
static final class d extends yj.q implements xj.a<com.joaomgcd.taskerm.util.j7> {
final String i;
d(String str) {
super(0);
this.i = str;
}
@Override
public final com.joaomgcd.taskerm.util.j7 invoke() {
return new sf.a(this.i);
}
}
static final class e extends yj.q implements xj.a<com.joaomgcd.taskerm.util.j7> {
final String i;
e(String str) {
super(0);
this.i = str;
}
@Override
public final com.joaomgcd.taskerm.util.j7 invoke() {
return new te.b(this.i);
}
}
static final class f extends yj.q implements xj.a<com.joaomgcd.taskerm.util.j7> {
final xj.a<com.joaomgcd.taskerm.util.j7> i;
f(xj.a<? extends com.joaomgcd.taskerm.util.j7> aVar) {
super(0);
this.i = aVar;
}
@Override
public final com.joaomgcd.taskerm.util.j7 invoke() {
return this.i.invoke();
}
}
static final class g extends yj.q implements xj.a<StructureType> {
public static final g i = new g();
g() {
super(0);
}
@Override
public final StructureType invoke() {
return null;
}
}
static final class h extends yj.q implements xj.l<String, StructureType> {
final Context i;
h(Context context) {
super(1);
this.i = context;
}
@Override
public final StructureType invoke(String str) {
yj.p.i(str, "realVarName");
return com.joaomgcd.taskerm.structuredoutput.b.a.a(this.i, str);
}
}
static final class i extends yj.q implements xj.p<Bundle, String, StructureType> {
public static final i i = new i();
i() {
super(2);
}
@Override
public final StructureType l(Bundle bundle, String str) {
yj.p.i(bundle, "bundle");
yj.p.i(str, "realVarName");
return lq.a.x(bundle, str);
}
}
static final class j extends yj.q implements xj.l<String, String> {
final Context i;
final String q;
j(Context context, String str) {
super(1);
this.i = context;
this.q = str;
}
@Override
public final String invoke(String str) {
yj.p.i(str, "it");
return kq.C0(this.i, str, this.q);
}
}
static final class k extends yj.q implements xj.l<String, StructureType> {
final Context i;
k(Context context) {
super(1);
this.i = context;
}
@Override
public final StructureType invoke(String str) {
yj.p.i(str, "it");
return lq.a.o(str, this.i);
}
}
static final class l extends yj.q implements xj.l<String, String> {
final Bundle i;
l(Bundle bundle) {
super(1);
this.i = bundle;
}
@Override
public final String invoke(String str) {
yj.p.i(str, "it");
return lq.a.C(this.i, str);
}
}
static final class m extends yj.q implements xj.l<String, StructureType> {
final Bundle i;
final Context q;
final String r;
m(Bundle bundle, Context context, String str) {
super(1);
this.i = bundle;
this.q = context;
this.r = str;
}
@Override
public final StructureType invoke(String str) {
yj.p.i(str, "it");
return lq.a.y(this.i, this.q, this.r);
}
}
static final class n extends yj.q implements xj.l<hg.z1, lj.e0> {
final Context i;
n(Context context) {
super(1);
this.i = context;
}
public final void a(hg.z1 z1Var) {
yj.p.i(z1Var, "$this$warnWithNotification");
a aVar = lq.a;
z1Var.T(aVar.m());
z1Var.N(aVar.n());
z1Var.S(new hg.h(this.i, "https://tasker.joaoapps.com/userguide/en/variables.html#json", true, null, 8, null));
}
@Override
public lj.e0 invoke(hg.z1 z1Var) {
a(z1Var);
return lj.e0.a;
}
}
static final class o extends yj.q implements xj.a<lj.e0> {
public static final o i = new o();
o() {
super(0);
}
public final void a() {
}
@Override
public lj.e0 invoke() {
a();
return lj.e0.a;
}
}
static final class p extends yj.q implements xj.l<hg.z1, lj.e0> {
final Context i;
p(Context context) {
super(1);
this.i = context;
}
public final void a(hg.z1 z1Var) {
yj.p.i(z1Var, "$this$warnWithNotification");
a aVar = lq.a;
z1Var.T(aVar.m());
z1Var.N(aVar.n());
z1Var.S(new hg.h(this.i, "https://tasker.joaoapps.com/userguide/en/variables.html#html", true, null, 8, null));
}
@Override
public lj.e0 invoke(hg.z1 z1Var) {
a(z1Var);
return lj.e0.a;
}
}
static final class q extends yj.q implements xj.a<lj.e0> {
public static final q i = new q();
q() {
super(0);
}
public final void a() {
}
@Override
public lj.e0 invoke() {
a();
return lj.e0.a;
}
}
static final class r extends yj.q implements xj.a<sf.a> {
final String i;
r(String str) {
super(0);
this.i = str;
}
@Override
public final sf.a invoke() {
return new sf.a(this.i);
}
}
static final class s extends yj.q implements xj.a<wf.l> {
final String i;
s(String str) {
super(0);
this.i = str;
}
@Override
public final wf.l invoke() {
return new wf.l(this.i);
}
}
static final class t extends yj.q implements xj.a<String> {
final com.joaomgcd.taskerm.util.j7 i;
final Bundle q;
final Context r;
final String s;
final String t;
t(com.joaomgcd.taskerm.util.j7 j7Var, Bundle bundle, Context context, String str, String str2) {
super(0);
this.i = j7Var;
this.q = bundle;
this.r = context;
this.s = str;
this.t = str2;
}
@Override
public final String invoke() {
Object e;
com.joaomgcd.taskerm.util.j7 j7Var = this.i;
if (j7Var instanceof wf.l) {
e = ((wf.l) this.i).i(this.t, lq.a.N(this.q, this.r, this.s));
} else {
e = j7Var.e(this.t);
}
if (e != null) {
return com.joaomgcd.taskerm.util.x2.C2(e, 10);
}
return null;
}
}
static final class u extends yj.q implements xj.a<lj.e0> {
public static final u i = new u();
u() {
super(0);
}
public final void a() {
}
@Override
public lj.e0 invoke() {
a();
return lj.e0.a;
}
}
static final class v extends yj.q implements xj.a<Boolean> {
public static final v i = new v();
v() {
super(0);
}
@Override
public final Boolean invoke() {
return Boolean.FALSE;
}
}
static final class w extends yj.q implements xj.l<String, Boolean> {
final Context i;
w(Context context) {
super(1);
this.i = context;
}
@Override
public final Boolean invoke(String str) {
yj.p.i(str, "realVarName");
return Boolean.valueOf(com.joaomgcd.taskerm.structuredoutput.a.a.a(this.i, str));
}
}
static final class x extends yj.q implements xj.p<Bundle, String, Boolean> {
public static final x i = new x();
x() {
super(2);
}
@Override
public final Boolean l(Bundle bundle, String str) {
yj.p.i(bundle, "bundle");
yj.p.i(str, "realVarName");
return Boolean.valueOf(bundle.getBoolean(lq.a.K(str)));
}
}
public a(yj.h hVar) {
this();
}
public final String C(Bundle bundle, String str) {
return com.joaomgcd.taskerm.util.z2.F(bundle.getString(str));
}
private final hk.k D() {
return (hk.k) lq.b.getValue();
}
private final hk.k E() {
return (hk.k) lq.c.getValue();
}
private final String G(Context context, String str, String str2, Bundle bundle, boolean z) {
return J(context, str, str2, bundle, z, new j(context, str2), new k(context));
}
private final String H(Context context, String str, String str2, Bundle bundle, boolean z) {
return bundle == null ? str2 : J(context, str, str2, bundle, z, new l(bundle), new m(bundle, context, str));
}
private final String J(Context context, String str, String str2, Bundle bundle, boolean z, xj.l<? super String, String> lVar, xj.l<? super String, ? extends StructureType> lVar2) {
StringBuilder sb;
String str3;
StringBuilder sb2;
if (str == null) {
return str2;
}
if (z) {
String invoke = lVar.invoke(str);
return invoke == null ? str2 : invoke;
}
if (!p(str)) {
String invoke2 = lVar.invoke(str);
return invoke2 == null ? str2 : invoke2;
}
StructureType invoke3 = lVar2.invoke(str);
if (invoke3 == null) {
List<String> s2 = s(str);
String F = com.joaomgcd.taskerm.util.z2.F(lVar.invoke(s2.get(0)));
if (F == null) {
return str2;
}
boolean q2 = q(str);
String str4 = s2.get(1);
if (q2) {
sb2 = new StringBuilder();
sb2.append(F);
sb2.append(".");
sb2.append((Object) str4);
} else {
sb2 = new StringBuilder();
sb2.append(F);
sb2.append("[");
sb2.append((Object) str4);
sb2.append("]");
}
return sb2.toString();
}
rn v2 = v(context, str, invoke3, bundle, z, lVar);
if (v2 != null) {
com.joaomgcd.taskerm.util.j7 a = v2.a();
String b2 = v2.b();
if (a == null) {
return str2;
}
String str5 = (String) com.joaomgcd.taskerm.util.x2.U4(null, new t(a, bundle, context, str, b2), 1, null);
return str5 == null ? str2 : str5;
}
String invoke4 = lVar.invoke(str);
if (invoke4 == null) {
return str2;
}
if (wf.m.o(invoke4)) {
z1.a aVar = hg.z1.A;
if (aVar.o(context, "potentialjsonalert")) {
wf.l lVar3 = (wf.l) com.joaomgcd.taskerm.util.x2.U4(null, new s(invoke4), 1, null);
if (lVar3 == null) {
return invoke4;
}
String f2 = lVar3.f();
if (f2 == null) {
f2 = "example";
}
if (kq.c1("%" + f2)) {
sb = new StringBuilder();
sb.append(str);
sb.append(".");
sb.append(f2);
} else {
sb = new StringBuilder();
sb.append(str);
sb.append("[");
sb.append(f2);
sb.append("]");
}
String sb3 = sb.toString();
String Q4 = com.joaomgcd.taskerm.util.x2.Q4(2131888353, context, new Object[0]);
Object e2 = lVar3.e(f2);
if (e2 == null || (str3 = e2.toString()) == null) {
str3 = "null";
}
pg.w0.B1(aVar.m(context, "potentialjsonalert", Q4, com.joaomgcd.taskerm.util.x2.Q4(2131888354, context, sb3, str3), new n(context)), context, o.i);
}
}
if (!sf.b.a(invoke4)) {
return invoke4;
}
z1.a aVar2 = hg.z1.A;
if (!aVar2.o(context, "potentialhtmlalert") || ((sf.a) com.joaomgcd.taskerm.util.x2.U4(null, new r(invoke4), 1, null)) == null) {
return invoke4;
}
pg.w0.B1(aVar2.m(context, "potentialhtmlalert", com.joaomgcd.taskerm.util.x2.Q4(2131888246, context, new Object[0]), com.joaomgcd.taskerm.util.x2.Q4(2131888247, context, str + "[div]"), new p(context)), context, q.i);
return invoke4;
}
public final String K(String str) {
if (O(str)) {
return str;
}
return str + "#@ohmyjsonsmartsearchdisabledOHNO!@#";
}
private final String L(String str) {
if (O(str)) {
return str;
}
return str + "#@superstructuretypeyeaaahh@#";
}
public final boolean N(Bundle bundle, Context context, String str) {
return ((Boolean) u(bundle, context, str, v.i, new w(context), x.i)).booleanValue();
}
public static void T(a aVar, Bundle bundle, String str, StructureType structureType, Context context, Boolean bool, int i2, Object obj) {
aVar.S(bundle, str, structureType, (i2 & 8) != 0 ? null : context, (i2 & 16) != 0 ? null : bool);
}
private static final SharedPreferences.Editor h(lj.j<? extends SharedPreferences.Editor> jVar) {
return jVar.getValue();
}
private static final v3 k(Bundle bundle, Context context, String str, List<String> list) {
ArrayList arrayList;
Object clone = bundle.clone();
yj.p.g(clone, "null cannot be cast to non-null type android.os.Bundle");
Bundle bundle2 = (Bundle) clone;
kq.N1(context, str, list, bundle2);
if (kq.W0(str)) {
arrayList = null;
} else {
arrayList = new ArrayList(kotlin.collections.r.v(list, 10));
int i2 = 0;
for (Object obj : list) {
int i3 = i2 + 1;
if (i2 < 0) {
kotlin.collections.r.u();
}
arrayList.add(str + i3);
i2 = i3;
}
}
return new v3(bundle2, null, arrayList, 2, null);
}
public final hg.w1 m() {
return new hg.w1(2131231834);
}
public final hg.l1 n() {
return new hg.l1("easystructureread", "Easy Data Reading", "Notifications related to easily reading data with Tasker like JSON or HTML.", 5, null, null, null, false, null, false, null, null, 4080, null);
}
public final StructureType o(String str, Context context) {
if (str == null || !p(str)) {
return null;
}
return com.joaomgcd.taskerm.structuredoutput.b.a.a(context, s(str).get(0));
}
private final boolean q(String str) {
return hk.o.N(str, ".", false, 2, null);
}
private final boolean r(String str) {
return hk.o.N(str, "[", false, 2, null) && hk.o.N(str, "]", false, 2, null);
}
private final List<String> s(String str) {
if (!r(str)) {
return kotlin.collections.r.o(hk.o.T0(str, ".", null, 2, null), hk.o.L0(str, ".", null, 2, null));
}
List A0 = hk.o.A0(str, new String[]{"["}, false, 0, 6, null);
String str2 = (String) A0.get(0);
List A02 = hk.o.A0((String) A0.get(1), new String[]{"]"}, false, 0, 6, null);
String str3 = (String) A02.get(0);
return kotlin.collections.r.o(str2, str3);
}
private final <T> T u(Bundle bundle, Context context, String str, xj.a<? extends T> aVar, xj.l<? super String, ? extends T> lVar, xj.p<? super Bundle, ? super String, ? extends T> pVar) {
if (bundle == null || str == null || !p(str)) {
return aVar.invoke();
}
String str2 = s(str).get(0);
return !com.joaomgcd.taskerm.util.z2.j0(str2) ? lVar.invoke(str2) : pVar.l(bundle, str2);
}
private final rn v(Context context, String str, StructureType structureType, Bundle bundle, boolean z, xj.l<? super String, String> lVar) {
String I;
if (!p(str)) {
return null;
}
List<String> s2 = s(str);
String str2 = s2.get(0);
String str3 = s2.get(1);
String invoke = lVar.invoke(str2);
if (invoke == null) {
return null;
}
if (hk.o.N(str3, "%", false, 2, null) && (I = I(context, str3, null, bundle, z)) != null) {
str3 = I;
}
if (wf.m.o(invoke)) {
return new rn(w(structureType, StructureType.JSON, new c(invoke)), str3);
}
if (sf.b.a(invoke)) {
return new rn(w(structureType, StructureType.HTML_XML, new d(invoke)), str3);
}
if (te.c.a(invoke)) {
return new rn(w(structureType, StructureType.CSV, new e(invoke)), str3);
}
return null;
}
private static final com.joaomgcd.taskerm.util.j7 w(StructureType structureType, StructureType structureType2, xj.a<? extends com.joaomgcd.taskerm.util.j7> aVar) {
if (com.joaomgcd.taskerm.util.x2.e0(structureType, StructureType.None, StructureType.Auto, structureType2)) {
return (com.joaomgcd.taskerm.util.j7) com.joaomgcd.taskerm.util.x2.U4(null, new f(aVar), 1, null);
}
return null;
}
public final List<String> A(Context context, String str, String str2, Bundle bundle) {
yj.p.i(context, "context");
yj.p.i(str, "arrayName");
yj.p.i(str2, "indexes");
List A0 = hk.o.A0(str2, new String[]{","}, false, 0, 6, null);
ArrayList arrayList = new ArrayList();
Iterator it = A0.iterator();
while (it.hasNext()) {
Integer m2 = hk.o.m((String) it.next());
if (m2 != null) {
arrayList.add(m2);
}
}
return B(context, str, arrayList, bundle);
}
public final List<String> B(Context context, String str, List<Integer> list, Bundle bundle) {
List<String> l2;
yj.p.i(context, "context");
yj.p.i(str, "arrayName");
yj.p.i(list, "indexes1Based");
ArrayList arrayList = new ArrayList(kotlin.collections.r.v(list, 10));
Iterator<T> it = list.iterator();
while (it.hasNext()) {
arrayList.add(Integer.valueOf(((Number) it.next()).intValue() - 1));
}
if (!hk.o.t(str, ")", false, 2, null)) {
str = str + "()";
}
String substring = str.substring(0, str.length() - 2);
yj.p.h(substring, "substring(...)");
w3 V = kq.V(context, str, bundle);
if (V == null || (l2 = V.c()) == null) {
l2 = kotlin.collections.r.l();
}
ArrayList arrayList2 = new ArrayList(kotlin.collections.r.v(arrayList, 10));
Iterator it2 = arrayList.iterator();
while (it2.hasNext()) {
int intValue = ((Number) it2.next()).intValue();
String str2 = (String) kotlin.collections.r.g0(l2, intValue);
if (str2 == null) {
str2 = substring + (intValue + 1);
}
arrayList2.add(str2);
}
return arrayList2;
}
public final w3 F(Context context, String str, String str2, Bundle bundle) {
yj.p.i(context, "context");
yj.p.i(str, "expr");
yj.p.i(str2, "lookupVarName");
w3 w3Var = new w3(kotlin.collections.r.d("0"), null);
hk.i c2 = hk.k.c(hk.o.N(str, "~R", false, 2, null) ? E() : D(), str, 0, 2, null);
if (c2 == null) {
return w3Var;
}
List<String> a = c2.a();
String str3 = (String) kotlin.collections.r.g0(a, 3);
if (str3 == null || str3.length() == 0) {
r7.G("Variables", "empty content specifier for $?");
return w3Var;
}
List<Integer> G1 = com.joaomgcd.taskerm.util.x2.G1(kq.c0(context, str2, kq.N(context, str3, bundle), bundle));
return G1 == null ? w3Var : new w3(B(context, str2, G1, bundle), com.joaomgcd.taskerm.util.z2.F((String) kotlin.collections.r.g0(a, 1)));
}
public final String I(Context context, String str, String str2, Bundle bundle, boolean z) {
StringBuilder sb;
yj.p.i(context, "context");
String F = com.joaomgcd.taskerm.util.z2.F(str);
if (F == null) {
return str2;
}
if (z || !p(F)) {
return kq.W0(F) ? H(context, str, str2, bundle, z) : kq.C0(context, F, str2);
}
List<String> s2 = s(F);
String str3 = s2.get(0);
String str4 = s2.get(1);
String I = I(context, str3, null, bundle, z);
if (I == null) {
return str2;
}
if (wf.m.o(I) || sf.b.a(I) || te.c.a(I)) {
return kq.W0(str3) ? H(context, str, str2, bundle, z) : G(context, str, str2, bundle, z);
}
if (q(F)) {
sb = new StringBuilder();
sb.append(I);
sb.append(".");
sb.append(str4);
} else {
sb = new StringBuilder();
sb.append(I);
sb.append("[");
sb.append(str4);
sb.append("]");
}
return sb.toString();
}
public final void M(Context context) {
yj.p.i(context, "context");
if (g1.r1(context)) {
return;
}
pg.w0.B1(z1.a.n(hg.z1.A, context, "winvarwihtoutaccessibility", com.joaomgcd.taskerm.util.x2.Q4(2131891106, context, new Object[0]), com.joaomgcd.taskerm.util.x2.Q4(2131891107, context, new Object[0]), null, 16, null), context, u.i);
}
public final boolean O(String str) {
if (str != null) {
return hk.o.t(str, "#@superstructuretypeyeaaahh@#", false, 2, null);
}
return false;
}
public final String P(Context context, String str, String str2, Bundle bundle) {
yj.p.i(context, "context");
yj.p.i(str, "arrayName");
yj.p.i(str2, "arrayJoiner");
return kotlin.collections.r.m0(com.joaomgcd.taskerm.util.z2.O(str, context, bundle), str2, null, null, 0, null, null, 62, null);
}
public final void Q(Bundle bundle, String str, StructureType structureType) {
T(this, bundle, str, structureType, null, null, 24, null);
}
public final void R(Bundle bundle, String str, StructureType structureType, Context context) {
T(this, bundle, str, structureType, context, null, 16, null);
}
public final void S(Bundle bundle, String str, StructureType structureType, Context context, Boolean bool) {
if (str == null || O(str)) {
return;
}
String L = L(str);
if (structureType == null) {
if (bundle != null) {
bundle.remove(L);
lj.e0 e0Var = lj.e0.a;
return;
}
return;
}
boolean booleanValue = bool != null ? bool.booleanValue() : false;
int valueForBundle = structureType.getValueForBundle();
if (!kq.W0(str)) {
if (context != null) {
com.joaomgcd.taskerm.structuredoutput.b.a.c(context, str, structureType);
com.joaomgcd.taskerm.structuredoutput.a.a.c(context, str, booleanValue);
return;
}
return;
}
if (bundle == null) {
return;
}
bundle.putInt(L, valueForBundle);
String K = K(str);
if (booleanValue) {
bundle.putBoolean(K, booleanValue);
} else {
bundle.remove(K);
}
}
public final String U(boolean z) {
return z ? "true" : "false";
}
public final void g(Context context, List<String> list, Bundle bundle) {
yj.p.i(context, "context");
if (list == null) {
return;
}
lj.j b2 = lj.k.b(new C0253a(context));
boolean z = false;
for (String str : list) {
if (!kq.W0(str)) {
h(b2).remove(str);
z = true;
} else if (bundle != null) {
bundle.remove(str);
}
}
if (z) {
h(b2).commit();
}
}
public final boolean i(String str, String str2) {
yj.p.i(str, "input");
yj.p.i(str2, "variable");
h1 l2 = l(str2);
if (l2 == null) {
return kq.L(str, str2, true);
}
h1 l3 = l(str);
if (l3 == null) {
return false;
}
return kq.L(str, l2.b(), true) && (l3.a() == l2.a());
}
public final v3 j(Context context, String str, Bundle bundle, String str2) {
String F;
com.joaomgcd.taskerm.util.j7 d2;
ArrayList arrayList;
yj.p.i(context, "context");
if (str == null || bundle == null || !kq.o1(str)) {
return null;
}
StructureType y = y(bundle, context, str);
if (y != null) {
rn v2 = v(context, str, y, bundle, false, new b(bundle, context));
com.joaomgcd.taskerm.util.j7 d3 = v2 != null ? v2.d() : null;
List<Object> h2 = d3 instanceof wf.l ? ((wf.l) d3).h(v2.c(), N(bundle, context, str)) : (v2 == null || (d2 = v2.d()) == null) ? null : d2.d(v2.c());
if (h2 != null) {
arrayList = new ArrayList(kotlin.collections.r.v(h2, 10));
Iterator<T> it = h2.iterator();
while (it.hasNext()) {
arrayList.add(com.joaomgcd.taskerm.util.x2.C2(it.next(), 10));
}
} else {
arrayList = null;
}
if (arrayList != null) {
return k(bundle, context, str, arrayList);
}
}
if (p(str) && (F = com.joaomgcd.taskerm.util.z2.F(I(context, str, str, bundle, false))) != null) {
if (str2 == null) {
str2 = "";
}
String str3 = F + "(" + str2 + ")";
if (str3 != null) {
return new v3(null, kotlin.collections.r.d(str3), null, 5, null);
}
}
return null;
}
public final h1 l(String str) {
yj.p.i(str, "variableNameInput");
hk.k kVar = new hk.k("(.+?)([\\d]+)$");
hk.k kVar2 = new hk.k("(.+?)\\(([\\d]+)\\)$");
hk.i f2 = kVar.f(str);
if (f2 == null && (f2 = kVar2.f(str)) == null) {
return null;
}
String str2 = f2.a().get(1);
Integer m2 = hk.o.m(f2.a().get(2));
if (m2 != null) {
return new h1(str2, m2.intValue());
}
return null;
}
public final boolean p(String str) {
if (str == null) {
return false;
}
return q(str) || r(str);
}
public final String t(String str) {
List<String> s2;
if (!p(str)) {
return str;
}
if (str == null || (s2 = s(str)) == null) {
return null;
}
return (String) kotlin.collections.r.g0(s2, 0);
}
public final StructureType x(Bundle bundle, String str) {
String L;
int i2;
if (bundle == null || str == null || (L = L(str)) == null || (i2 = bundle.getInt(L)) == 0) {
return null;
}
return (StructureType) ((Enum) com.joaomgcd.taskerm.util.x2.I4(i2, StructureType.class));
}
public final StructureType y(Bundle bundle, Context context, String str) {
yj.p.i(context, "context");
return (StructureType) u(bundle, context, str, g.i, new h(context), i.i);
}
public final String z(String str) {
yj.p.i(str, "regularVarName");
return L(str);
}
private a() {
}
}
static final class b extends yj.q implements xj.a<hk.k> {
public static final b i = new b();
b() {
super(0);
}
@Override
public final hk.k invoke() {
return new hk.k("^\\$((.|\n)*)\\?(.+)");
}
}
static final class c extends yj.q implements xj.a<hk.k> {
public static final c i = new c();
c() {
super(0);
}
@Override
public final hk.k invoke() {
return new hk.k("^\\$((.|\n)*)\\?(!?~R.+)");
}
}
public static final void c(Context context, List<String> list, Bundle bundle) {
a.g(context, list, bundle);
}
public static final boolean d(String str, String str2) {
return a.i(str, str2);
}
public static final v3 e(Context context, String str, Bundle bundle, String str2) {
return a.j(context, str, bundle, str2);
}
public static final boolean f(String str) {
return a.p(str);
}
public static final String g(String str) {
return a.t(str);
}
public static final List<String> h(Context context, String str, String str2, Bundle bundle) {
return a.A(context, str, str2, bundle);
}
public static final w3 i(Context context, String str, String str2, Bundle bundle) {
return a.F(context, str, str2, bundle);
}
public static final String j(Context context, String str, String str2, Bundle bundle, boolean z) {
return a.I(context, str, str2, bundle, z);
}
public static final void k(Context context) {
a.M(context);
}
public static final boolean l(String str) {
return a.O(str);
}
public static final String m(Context context, String str, String str2, Bundle bundle) {
return a.P(context, str, str2, bundle);
}
public static final void n(Bundle bundle, String str, StructureType structureType) {
a.Q(bundle, str, structureType);
}
public static final void o(Bundle bundle, String str, StructureType structureType, Context context) {
a.R(bundle, str, structureType, context);
}
public static final String p(boolean z) {
return a.U(z);
}
}