102 lines
2.4 KiB
Java
102 lines
2.4 KiB
Java
/*
|
|
* Decompiled with CFR 0.152.
|
|
*/
|
|
package com.tridium.sys.schema;
|
|
|
|
import com.tridium.sys.engine.SlotKnobs;
|
|
import javax.baja.naming.SlotPath;
|
|
import javax.baja.sys.BFacets;
|
|
import javax.baja.sys.Context;
|
|
import javax.baja.sys.Slot;
|
|
import javax.baja.sys.Type;
|
|
import javax.baja.util.Lexicon;
|
|
|
|
public abstract class NSlot
|
|
implements Slot {
|
|
public int index;
|
|
Type declaringType;
|
|
String name;
|
|
String displayName;
|
|
int flags;
|
|
boolean isFrozen;
|
|
SlotKnobs knobs;
|
|
BFacets facets;
|
|
|
|
public final Type getDeclaringType() {
|
|
return this.declaringType;
|
|
}
|
|
|
|
public final String getName() {
|
|
return this.name;
|
|
}
|
|
|
|
public final String getDefaultDisplayName(Context context) {
|
|
try {
|
|
String string = this.declaringType.getModule().getModuleName();
|
|
String string2 = Lexicon.make(string, context).get(this.name);
|
|
if (string2 != null) {
|
|
return string2;
|
|
}
|
|
}
|
|
catch (Throwable throwable) {
|
|
throwable.printStackTrace();
|
|
}
|
|
if (this.displayName == null) {
|
|
this.displayName = SlotPath.unescape(this.name);
|
|
}
|
|
return this.displayName;
|
|
}
|
|
|
|
public final boolean isFrozen() {
|
|
return this.isFrozen;
|
|
}
|
|
|
|
public final boolean isDynamic() {
|
|
return this.isFrozen ^ true;
|
|
}
|
|
|
|
public final int getDefaultFlags() {
|
|
return this.flags;
|
|
}
|
|
|
|
public BFacets getFacets() {
|
|
return this.facets;
|
|
}
|
|
|
|
public final boolean equals(Object object) {
|
|
NSlot nSlot = (NSlot)object;
|
|
if (this == nSlot) {
|
|
return true;
|
|
}
|
|
boolean bl = false;
|
|
if (this.index == nSlot.index) {
|
|
bl = true;
|
|
}
|
|
return bl;
|
|
}
|
|
|
|
boolean equivalent(NSlot nSlot) {
|
|
boolean bl = false;
|
|
if (this.name.equals(nSlot.name) && this.flags == nSlot.flags && this.isFrozen == nSlot.isFrozen && this.facets.equals(nSlot.facets)) {
|
|
bl = true;
|
|
}
|
|
return bl;
|
|
}
|
|
|
|
void copyFrom(NSlot nSlot) {
|
|
this.index = nSlot.index;
|
|
this.declaringType = nSlot.declaringType;
|
|
this.name = nSlot.name;
|
|
this.displayName = nSlot.displayName;
|
|
this.isFrozen = nSlot.isFrozen;
|
|
}
|
|
|
|
NSlot(String string, int n, BFacets bFacets, boolean bl) {
|
|
this.name = string;
|
|
this.flags = n;
|
|
this.facets = bFacets;
|
|
this.isFrozen = bl;
|
|
}
|
|
}
|
|
|