134 lines
3.8 KiB
Java
134 lines
3.8 KiB
Java
/*
|
|
* Decompiled with CFR 0.152.
|
|
*/
|
|
package javax.baja.util;
|
|
|
|
import javax.baja.naming.BOrd;
|
|
import javax.baja.space.BComponentSpace;
|
|
import javax.baja.sys.Action;
|
|
import javax.baja.sys.BAction;
|
|
import javax.baja.sys.BComponent;
|
|
import javax.baja.sys.BFacets;
|
|
import javax.baja.sys.BValue;
|
|
import javax.baja.sys.Knob;
|
|
import javax.baja.sys.Slot;
|
|
import javax.baja.sys.Sys;
|
|
import javax.baja.sys.Type;
|
|
|
|
/*
|
|
* Illegal identifiers - consider using --renameillegalidents true
|
|
*/
|
|
public class BCompositeAction
|
|
extends BAction {
|
|
public static final Type TYPE;
|
|
static /* synthetic */ Class class$javax$baja$util$BCompositeAction;
|
|
|
|
public Type getType() {
|
|
return TYPE;
|
|
}
|
|
|
|
public Mirror getMirror() {
|
|
try {
|
|
BComponent bComponent = this.getParentComponent();
|
|
if (bComponent == null) {
|
|
return null;
|
|
}
|
|
BComponentSpace bComponentSpace = bComponent.getComponentSpace();
|
|
if (bComponentSpace == null) {
|
|
return null;
|
|
}
|
|
Knob[] knobArray = bComponent.getKnobs(this.getPropertyInParent());
|
|
if (knobArray.length == 0) {
|
|
return null;
|
|
}
|
|
Knob knob = knobArray[0];
|
|
BOrd bOrd = knob.getTargetOrd();
|
|
String string = knob.getTargetSlotName();
|
|
BComponent bComponent2 = (BComponent)bOrd.get(bComponentSpace);
|
|
Slot slot = bComponent2.getSlot(string);
|
|
if (slot == this.getPropertyInParent()) {
|
|
return null;
|
|
}
|
|
if (!(slot instanceof Action)) {
|
|
return null;
|
|
}
|
|
return new Mirror(knob, bComponent2, (Action)slot);
|
|
}
|
|
catch (Exception exception) {
|
|
exception.printStackTrace();
|
|
return null;
|
|
}
|
|
}
|
|
|
|
public Type getParameterType() {
|
|
Mirror mirror = this.getMirror();
|
|
if (mirror != null) {
|
|
return mirror.action.getParameterType();
|
|
}
|
|
return null;
|
|
}
|
|
|
|
public BValue getParameterDefault() {
|
|
Mirror mirror = this.getMirror();
|
|
if (mirror != null) {
|
|
mirror.component.lease();
|
|
return mirror.component.getActionParameterDefault(mirror.action);
|
|
}
|
|
return null;
|
|
}
|
|
|
|
public BFacets getFacets() {
|
|
Mirror mirror = this.getMirror();
|
|
if (mirror != null) {
|
|
return mirror.component.getSlotFacets(mirror.action);
|
|
}
|
|
return null;
|
|
}
|
|
|
|
public BValue invoke(BComponent bComponent, BValue bValue) {
|
|
return null;
|
|
}
|
|
|
|
public Type getReturnType() {
|
|
return null;
|
|
}
|
|
|
|
static /* synthetic */ Class class(String string, boolean bl) {
|
|
try {
|
|
Class<?> clazz = Class.forName(string);
|
|
if (!bl) {
|
|
clazz = clazz.getComponentType();
|
|
}
|
|
return clazz;
|
|
}
|
|
catch (ClassNotFoundException classNotFoundException) {
|
|
throw new NoClassDefFoundError(classNotFoundException.getMessage());
|
|
}
|
|
}
|
|
|
|
static {
|
|
Class clazz = class$javax$baja$util$BCompositeAction;
|
|
if (clazz == null) {
|
|
clazz = class$javax$baja$util$BCompositeAction = BCompositeAction.class("[Ljavax.baja.util.BCompositeAction;", false);
|
|
}
|
|
TYPE = Sys.loadType(clazz);
|
|
}
|
|
|
|
public static class Mirror {
|
|
public Knob knob;
|
|
public BComponent component;
|
|
public Action action;
|
|
|
|
public String toString() {
|
|
return this.component.toPathString() + '.' + this.action.getName();
|
|
}
|
|
|
|
public Mirror(Knob knob, BComponent bComponent, Action action) {
|
|
this.knob = knob;
|
|
this.component = bComponent;
|
|
this.action = action;
|
|
}
|
|
}
|
|
}
|
|
|