mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-20 08:46:43 +08:00
Moved @Null for method return values to the same line.
This commit is contained in:
parent
afab54aaa1
commit
dea3e3594c
@ -792,8 +792,7 @@ public class AnimationState {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** Returns the track entry for the animation currently playing on the track, or null if no animation is currently playing. */
|
/** Returns the track entry for the animation currently playing on the track, or null if no animation is currently playing. */
|
||||||
@Null
|
public @Null TrackEntry getCurrent (int trackIndex) {
|
||||||
public TrackEntry getCurrent (int trackIndex) {
|
|
||||||
if (trackIndex < 0) throw new IllegalArgumentException("trackIndex must be >= 0.");
|
if (trackIndex < 0) throw new IllegalArgumentException("trackIndex must be >= 0.");
|
||||||
if (trackIndex >= tracks.size) return null;
|
if (trackIndex >= tracks.size) return null;
|
||||||
return tracks.get(trackIndex);
|
return tracks.get(trackIndex);
|
||||||
@ -1031,8 +1030,7 @@ public class AnimationState {
|
|||||||
* <p>
|
* <p>
|
||||||
* A track entry returned from {@link AnimationState#setAnimation(int, Animation, boolean)} is already the current animation
|
* A track entry returned from {@link AnimationState#setAnimation(int, Animation, boolean)} is already the current animation
|
||||||
* for the track, so the track entry listener {@link AnimationStateListener#start(TrackEntry)} will not be called. */
|
* for the track, so the track entry listener {@link AnimationStateListener#start(TrackEntry)} will not be called. */
|
||||||
@Null
|
public @Null AnimationStateListener getListener () {
|
||||||
public AnimationStateListener getListener () {
|
|
||||||
return listener;
|
return listener;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1087,8 +1085,7 @@ public class AnimationState {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** The animation queued to start after this animation, or null. <code>next</code> makes up a linked list. */
|
/** The animation queued to start after this animation, or null. <code>next</code> makes up a linked list. */
|
||||||
@Null
|
public @Null TrackEntry getNext () {
|
||||||
public TrackEntry getNext () {
|
|
||||||
return next;
|
return next;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1147,15 +1144,13 @@ public class AnimationState {
|
|||||||
|
|
||||||
/** The track entry for the previous animation when mixing from the previous animation to this animation, or null if no
|
/** The track entry for the previous animation when mixing from the previous animation to this animation, or null if no
|
||||||
* mixing is currently occuring. When mixing from multiple animations, <code>mixingFrom</code> makes up a linked list. */
|
* mixing is currently occuring. When mixing from multiple animations, <code>mixingFrom</code> makes up a linked list. */
|
||||||
@Null
|
public @Null TrackEntry getMixingFrom () {
|
||||||
public TrackEntry getMixingFrom () {
|
|
||||||
return mixingFrom;
|
return mixingFrom;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** The track entry for the next animation when mixing from this animation to the next animation, or null if no mixing is
|
/** The track entry for the next animation when mixing from this animation to the next animation, or null if no mixing is
|
||||||
* currently occuring. When mixing to multiple animations, <code>mixingTo</code> makes up a linked list. */
|
* currently occuring. When mixing to multiple animations, <code>mixingTo</code> makes up a linked list. */
|
||||||
@Null
|
public @Null TrackEntry getMixingTo () {
|
||||||
public TrackEntry getMixingTo () {
|
|
||||||
return mixingTo;
|
return mixingTo;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -225,8 +225,7 @@ public class Bone implements Updatable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** The parent bone, or null if this is the root bone. */
|
/** The parent bone, or null if this is the root bone. */
|
||||||
@Null
|
public @Null Bone getParent () {
|
||||||
public Bone getParent () {
|
|
||||||
return parent;
|
return parent;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -79,8 +79,7 @@ public class BoneData {
|
|||||||
return name;
|
return name;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Null
|
public @Null BoneData getParent () {
|
||||||
public BoneData getParent () {
|
|
||||||
return parent;
|
return parent;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -484,8 +484,7 @@ public class Skeleton {
|
|||||||
|
|
||||||
/** Finds a bone by comparing each bone's name. It is more efficient to cache the results of this method than to call it
|
/** Finds a bone by comparing each bone's name. It is more efficient to cache the results of this method than to call it
|
||||||
* repeatedly. */
|
* repeatedly. */
|
||||||
@Null
|
public @Null Bone findBone (String boneName) {
|
||||||
public Bone findBone (String boneName) {
|
|
||||||
if (boneName == null) throw new IllegalArgumentException("boneName cannot be null.");
|
if (boneName == null) throw new IllegalArgumentException("boneName cannot be null.");
|
||||||
Object[] bones = this.bones.items;
|
Object[] bones = this.bones.items;
|
||||||
for (int i = 0, n = this.bones.size; i < n; i++) {
|
for (int i = 0, n = this.bones.size; i < n; i++) {
|
||||||
@ -502,8 +501,7 @@ public class Skeleton {
|
|||||||
|
|
||||||
/** Finds a slot by comparing each slot's name. It is more efficient to cache the results of this method than to call it
|
/** Finds a slot by comparing each slot's name. It is more efficient to cache the results of this method than to call it
|
||||||
* repeatedly. */
|
* repeatedly. */
|
||||||
@Null
|
public @Null Slot findSlot (String slotName) {
|
||||||
public Slot findSlot (String slotName) {
|
|
||||||
if (slotName == null) throw new IllegalArgumentException("slotName cannot be null.");
|
if (slotName == null) throw new IllegalArgumentException("slotName cannot be null.");
|
||||||
Object[] slots = this.slots.items;
|
Object[] slots = this.slots.items;
|
||||||
for (int i = 0, n = this.slots.size; i < n; i++) {
|
for (int i = 0, n = this.slots.size; i < n; i++) {
|
||||||
@ -524,8 +522,7 @@ public class Skeleton {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** The skeleton's current skin. */
|
/** The skeleton's current skin. */
|
||||||
@Null
|
public @Null Skin getSkin () {
|
||||||
public Skin getSkin () {
|
|
||||||
return skin;
|
return skin;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -573,8 +570,7 @@ public class Skeleton {
|
|||||||
* name.
|
* name.
|
||||||
* <p>
|
* <p>
|
||||||
* See {@link #getAttachment(int, String)}. */
|
* See {@link #getAttachment(int, String)}. */
|
||||||
@Null
|
public @Null Attachment getAttachment (String slotName, String attachmentName) {
|
||||||
public Attachment getAttachment (String slotName, String attachmentName) {
|
|
||||||
SlotData slot = data.findSlot(slotName);
|
SlotData slot = data.findSlot(slotName);
|
||||||
if (slot == null) throw new IllegalArgumentException("Slot not found: " + slotName);
|
if (slot == null) throw new IllegalArgumentException("Slot not found: " + slotName);
|
||||||
return getAttachment(slot.getIndex(), attachmentName);
|
return getAttachment(slot.getIndex(), attachmentName);
|
||||||
@ -584,8 +580,7 @@ public class Skeleton {
|
|||||||
* attachment name. First the skin is checked and if the attachment was not found, the default skin is checked.
|
* attachment name. First the skin is checked and if the attachment was not found, the default skin is checked.
|
||||||
* <p>
|
* <p>
|
||||||
* See <a href="http://esotericsoftware.com/spine-runtime-skins">Runtime skins</a> in the Spine Runtimes Guide. */
|
* See <a href="http://esotericsoftware.com/spine-runtime-skins">Runtime skins</a> in the Spine Runtimes Guide. */
|
||||||
@Null
|
public @Null Attachment getAttachment (int slotIndex, String attachmentName) {
|
||||||
public Attachment getAttachment (int slotIndex, String attachmentName) {
|
|
||||||
if (attachmentName == null) throw new IllegalArgumentException("attachmentName cannot be null.");
|
if (attachmentName == null) throw new IllegalArgumentException("attachmentName cannot be null.");
|
||||||
if (skin != null) {
|
if (skin != null) {
|
||||||
Attachment attachment = skin.getAttachment(slotIndex, attachmentName);
|
Attachment attachment = skin.getAttachment(slotIndex, attachmentName);
|
||||||
@ -618,8 +613,7 @@ public class Skeleton {
|
|||||||
|
|
||||||
/** Finds an IK constraint by comparing each IK constraint's name. It is more efficient to cache the results of this method
|
/** Finds an IK constraint by comparing each IK constraint's name. It is more efficient to cache the results of this method
|
||||||
* than to call it repeatedly. */
|
* than to call it repeatedly. */
|
||||||
@Null
|
public @Null IkConstraint findIkConstraint (String constraintName) {
|
||||||
public IkConstraint findIkConstraint (String constraintName) {
|
|
||||||
if (constraintName == null) throw new IllegalArgumentException("constraintName cannot be null.");
|
if (constraintName == null) throw new IllegalArgumentException("constraintName cannot be null.");
|
||||||
Object[] ikConstraints = this.ikConstraints.items;
|
Object[] ikConstraints = this.ikConstraints.items;
|
||||||
for (int i = 0, n = this.ikConstraints.size; i < n; i++) {
|
for (int i = 0, n = this.ikConstraints.size; i < n; i++) {
|
||||||
@ -636,8 +630,7 @@ public class Skeleton {
|
|||||||
|
|
||||||
/** Finds a transform constraint by comparing each transform constraint's name. It is more efficient to cache the results of
|
/** Finds a transform constraint by comparing each transform constraint's name. It is more efficient to cache the results of
|
||||||
* this method than to call it repeatedly. */
|
* this method than to call it repeatedly. */
|
||||||
@Null
|
public @Null TransformConstraint findTransformConstraint (String constraintName) {
|
||||||
public TransformConstraint findTransformConstraint (String constraintName) {
|
|
||||||
if (constraintName == null) throw new IllegalArgumentException("constraintName cannot be null.");
|
if (constraintName == null) throw new IllegalArgumentException("constraintName cannot be null.");
|
||||||
Object[] transformConstraints = this.transformConstraints.items;
|
Object[] transformConstraints = this.transformConstraints.items;
|
||||||
for (int i = 0, n = this.transformConstraints.size; i < n; i++) {
|
for (int i = 0, n = this.transformConstraints.size; i < n; i++) {
|
||||||
@ -654,8 +647,7 @@ public class Skeleton {
|
|||||||
|
|
||||||
/** Finds a path constraint by comparing each path constraint's name. It is more efficient to cache the results of this method
|
/** Finds a path constraint by comparing each path constraint's name. It is more efficient to cache the results of this method
|
||||||
* than to call it repeatedly. */
|
* than to call it repeatedly. */
|
||||||
@Null
|
public @Null PathConstraint findPathConstraint (String constraintName) {
|
||||||
public PathConstraint findPathConstraint (String constraintName) {
|
|
||||||
if (constraintName == null) throw new IllegalArgumentException("constraintName cannot be null.");
|
if (constraintName == null) throw new IllegalArgumentException("constraintName cannot be null.");
|
||||||
Object[] pathConstraints = this.pathConstraints.items;
|
Object[] pathConstraints = this.pathConstraints.items;
|
||||||
for (int i = 0, n = this.pathConstraints.size; i < n; i++) {
|
for (int i = 0, n = this.pathConstraints.size; i < n; i++) {
|
||||||
|
|||||||
@ -312,8 +312,7 @@ public class SkeletonBinary extends SkeletonLoader {
|
|||||||
return skeletonData;
|
return skeletonData;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Null
|
private @Null Skin readSkin (SkeletonInput input, SkeletonData skeletonData, boolean defaultSkin, boolean nonessential)
|
||||||
private Skin readSkin (SkeletonInput input, SkeletonData skeletonData, boolean defaultSkin, boolean nonessential)
|
|
||||||
throws IOException {
|
throws IOException {
|
||||||
|
|
||||||
Skin skin;
|
Skin skin;
|
||||||
@ -920,8 +919,7 @@ public class SkeletonBinary extends SkeletonLoader {
|
|||||||
super(file.read(512));
|
super(file.read(512));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Null
|
public @Null String readStringRef () throws IOException {
|
||||||
public String readStringRef () throws IOException {
|
|
||||||
int index = readInt(true);
|
int index = readInt(true);
|
||||||
return index == 0 ? null : strings[index - 1];
|
return index == 0 ? null : strings[index - 1];
|
||||||
}
|
}
|
||||||
|
|||||||
@ -143,8 +143,7 @@ public class SkeletonBounds {
|
|||||||
|
|
||||||
/** Returns the first bounding box attachment that contains the point, or null. When doing many checks, it is usually more
|
/** Returns the first bounding box attachment that contains the point, or null. When doing many checks, it is usually more
|
||||||
* efficient to only call this method if {@link #aabbContainsPoint(float, float)} returns true. */
|
* efficient to only call this method if {@link #aabbContainsPoint(float, float)} returns true. */
|
||||||
@Null
|
public @Null BoundingBoxAttachment containsPoint (float x, float y) {
|
||||||
public BoundingBoxAttachment containsPoint (float x, float y) {
|
|
||||||
Object[] polygons = this.polygons.items;
|
Object[] polygons = this.polygons.items;
|
||||||
for (int i = 0, n = this.polygons.size; i < n; i++)
|
for (int i = 0, n = this.polygons.size; i < n; i++)
|
||||||
if (containsPoint((FloatArray)polygons[i], x, y)) return boundingBoxes.get(i);
|
if (containsPoint((FloatArray)polygons[i], x, y)) return boundingBoxes.get(i);
|
||||||
@ -174,8 +173,7 @@ public class SkeletonBounds {
|
|||||||
/** Returns the first bounding box attachment that contains any part of the line segment, or null. When doing many checks, it
|
/** Returns the first bounding box attachment that contains any part of the line segment, or null. When doing many checks, it
|
||||||
* is usually more efficient to only call this method if {@link #aabbIntersectsSegment(float, float, float, float)} returns
|
* is usually more efficient to only call this method if {@link #aabbIntersectsSegment(float, float, float, float)} returns
|
||||||
* true. */
|
* true. */
|
||||||
@Null
|
public @Null BoundingBoxAttachment intersectsSegment (float x1, float y1, float x2, float y2) {
|
||||||
public BoundingBoxAttachment intersectsSegment (float x1, float y1, float x2, float y2) {
|
|
||||||
Object[] polygons = this.polygons.items;
|
Object[] polygons = this.polygons.items;
|
||||||
for (int i = 0, n = this.polygons.size; i < n; i++)
|
for (int i = 0, n = this.polygons.size; i < n; i++)
|
||||||
if (intersectsSegment((FloatArray)polygons[i], x1, y1, x2, y2)) return boundingBoxes.get(i);
|
if (intersectsSegment((FloatArray)polygons[i], x1, y1, x2, y2)) return boundingBoxes.get(i);
|
||||||
@ -248,8 +246,7 @@ public class SkeletonBounds {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** Returns the polygon for the specified bounding box, or null. */
|
/** Returns the polygon for the specified bounding box, or null. */
|
||||||
@Null
|
public @Null FloatArray getPolygon (BoundingBoxAttachment boundingBox) {
|
||||||
public FloatArray getPolygon (BoundingBoxAttachment boundingBox) {
|
|
||||||
if (boundingBox == null) throw new IllegalArgumentException("boundingBox cannot be null.");
|
if (boundingBox == null) throw new IllegalArgumentException("boundingBox cannot be null.");
|
||||||
int index = boundingBoxes.indexOf(boundingBox, true);
|
int index = boundingBoxes.indexOf(boundingBox, true);
|
||||||
return index == -1 ? null : polygons.get(index);
|
return index == -1 ? null : polygons.get(index);
|
||||||
|
|||||||
@ -67,8 +67,7 @@ public class SkeletonData {
|
|||||||
|
|
||||||
/** Finds a bone by comparing each bone's name. It is more efficient to cache the results of this method than to call it
|
/** Finds a bone by comparing each bone's name. It is more efficient to cache the results of this method than to call it
|
||||||
* multiple times. */
|
* multiple times. */
|
||||||
@Null
|
public @Null BoneData findBone (String boneName) {
|
||||||
public BoneData findBone (String boneName) {
|
|
||||||
if (boneName == null) throw new IllegalArgumentException("boneName cannot be null.");
|
if (boneName == null) throw new IllegalArgumentException("boneName cannot be null.");
|
||||||
Object[] bones = this.bones.items;
|
Object[] bones = this.bones.items;
|
||||||
for (int i = 0, n = this.bones.size; i < n; i++) {
|
for (int i = 0, n = this.bones.size; i < n; i++) {
|
||||||
@ -87,8 +86,7 @@ public class SkeletonData {
|
|||||||
|
|
||||||
/** Finds a slot by comparing each slot's name. It is more efficient to cache the results of this method than to call it
|
/** Finds a slot by comparing each slot's name. It is more efficient to cache the results of this method than to call it
|
||||||
* multiple times. */
|
* multiple times. */
|
||||||
@Null
|
public @Null SlotData findSlot (String slotName) {
|
||||||
public SlotData findSlot (String slotName) {
|
|
||||||
if (slotName == null) throw new IllegalArgumentException("slotName cannot be null.");
|
if (slotName == null) throw new IllegalArgumentException("slotName cannot be null.");
|
||||||
Object[] slots = this.slots.items;
|
Object[] slots = this.slots.items;
|
||||||
for (int i = 0, n = this.slots.size; i < n; i++) {
|
for (int i = 0, n = this.slots.size; i < n; i++) {
|
||||||
@ -103,8 +101,7 @@ public class SkeletonData {
|
|||||||
/** The skeleton's default skin. By default this skin contains all attachments that were not in a skin in Spine.
|
/** The skeleton's default skin. By default this skin contains all attachments that were not in a skin in Spine.
|
||||||
* <p>
|
* <p>
|
||||||
* See {@link Skeleton#getAttachment(int, String)}. */
|
* See {@link Skeleton#getAttachment(int, String)}. */
|
||||||
@Null
|
public @Null Skin getDefaultSkin () {
|
||||||
public Skin getDefaultSkin () {
|
|
||||||
return defaultSkin;
|
return defaultSkin;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -114,8 +111,7 @@ public class SkeletonData {
|
|||||||
|
|
||||||
/** Finds a skin by comparing each skin's name. It is more efficient to cache the results of this method than to call it
|
/** Finds a skin by comparing each skin's name. It is more efficient to cache the results of this method than to call it
|
||||||
* multiple times. */
|
* multiple times. */
|
||||||
@Null
|
public @Null Skin findSkin (String skinName) {
|
||||||
public Skin findSkin (String skinName) {
|
|
||||||
if (skinName == null) throw new IllegalArgumentException("skinName cannot be null.");
|
if (skinName == null) throw new IllegalArgumentException("skinName cannot be null.");
|
||||||
for (Skin skin : skins)
|
for (Skin skin : skins)
|
||||||
if (skin.name.equals(skinName)) return skin;
|
if (skin.name.equals(skinName)) return skin;
|
||||||
@ -131,8 +127,7 @@ public class SkeletonData {
|
|||||||
|
|
||||||
/** Finds an event by comparing each events's name. It is more efficient to cache the results of this method than to call it
|
/** Finds an event by comparing each events's name. It is more efficient to cache the results of this method than to call it
|
||||||
* multiple times. */
|
* multiple times. */
|
||||||
@Null
|
public @Null EventData findEvent (String eventDataName) {
|
||||||
public EventData findEvent (String eventDataName) {
|
|
||||||
if (eventDataName == null) throw new IllegalArgumentException("eventDataName cannot be null.");
|
if (eventDataName == null) throw new IllegalArgumentException("eventDataName cannot be null.");
|
||||||
for (EventData eventData : events)
|
for (EventData eventData : events)
|
||||||
if (eventData.name.equals(eventDataName)) return eventData;
|
if (eventData.name.equals(eventDataName)) return eventData;
|
||||||
@ -153,8 +148,7 @@ public class SkeletonData {
|
|||||||
|
|
||||||
/** Finds an animation by comparing each animation's name. It is more efficient to cache the results of this method than to
|
/** Finds an animation by comparing each animation's name. It is more efficient to cache the results of this method than to
|
||||||
* call it multiple times. */
|
* call it multiple times. */
|
||||||
@Null
|
public @Null Animation findAnimation (String animationName) {
|
||||||
public Animation findAnimation (String animationName) {
|
|
||||||
if (animationName == null) throw new IllegalArgumentException("animationName cannot be null.");
|
if (animationName == null) throw new IllegalArgumentException("animationName cannot be null.");
|
||||||
Object[] animations = this.animations.items;
|
Object[] animations = this.animations.items;
|
||||||
for (int i = 0, n = this.animations.size; i < n; i++) {
|
for (int i = 0, n = this.animations.size; i < n; i++) {
|
||||||
@ -173,8 +167,7 @@ public class SkeletonData {
|
|||||||
|
|
||||||
/** Finds an IK constraint by comparing each IK constraint's name. It is more efficient to cache the results of this method
|
/** Finds an IK constraint by comparing each IK constraint's name. It is more efficient to cache the results of this method
|
||||||
* than to call it multiple times. */
|
* than to call it multiple times. */
|
||||||
@Null
|
public @Null IkConstraintData findIkConstraint (String constraintName) {
|
||||||
public IkConstraintData findIkConstraint (String constraintName) {
|
|
||||||
if (constraintName == null) throw new IllegalArgumentException("constraintName cannot be null.");
|
if (constraintName == null) throw new IllegalArgumentException("constraintName cannot be null.");
|
||||||
Object[] ikConstraints = this.ikConstraints.items;
|
Object[] ikConstraints = this.ikConstraints.items;
|
||||||
for (int i = 0, n = this.ikConstraints.size; i < n; i++) {
|
for (int i = 0, n = this.ikConstraints.size; i < n; i++) {
|
||||||
@ -193,8 +186,7 @@ public class SkeletonData {
|
|||||||
|
|
||||||
/** Finds a transform constraint by comparing each transform constraint's name. It is more efficient to cache the results of
|
/** Finds a transform constraint by comparing each transform constraint's name. It is more efficient to cache the results of
|
||||||
* this method than to call it multiple times. */
|
* this method than to call it multiple times. */
|
||||||
@Null
|
public @Null TransformConstraintData findTransformConstraint (String constraintName) {
|
||||||
public TransformConstraintData findTransformConstraint (String constraintName) {
|
|
||||||
if (constraintName == null) throw new IllegalArgumentException("constraintName cannot be null.");
|
if (constraintName == null) throw new IllegalArgumentException("constraintName cannot be null.");
|
||||||
Object[] transformConstraints = this.transformConstraints.items;
|
Object[] transformConstraints = this.transformConstraints.items;
|
||||||
for (int i = 0, n = this.transformConstraints.size; i < n; i++) {
|
for (int i = 0, n = this.transformConstraints.size; i < n; i++) {
|
||||||
@ -213,8 +205,7 @@ public class SkeletonData {
|
|||||||
|
|
||||||
/** Finds a path constraint by comparing each path constraint's name. It is more efficient to cache the results of this method
|
/** Finds a path constraint by comparing each path constraint's name. It is more efficient to cache the results of this method
|
||||||
* than to call it multiple times. */
|
* than to call it multiple times. */
|
||||||
@Null
|
public @Null PathConstraintData findPathConstraint (String constraintName) {
|
||||||
public PathConstraintData findPathConstraint (String constraintName) {
|
|
||||||
if (constraintName == null) throw new IllegalArgumentException("constraintName cannot be null.");
|
if (constraintName == null) throw new IllegalArgumentException("constraintName cannot be null.");
|
||||||
Object[] pathConstraints = this.pathConstraints.items;
|
Object[] pathConstraints = this.pathConstraints.items;
|
||||||
for (int i = 0, n = this.pathConstraints.size; i < n; i++) {
|
for (int i = 0, n = this.pathConstraints.size; i < n; i++) {
|
||||||
@ -227,8 +218,7 @@ public class SkeletonData {
|
|||||||
// ---
|
// ---
|
||||||
|
|
||||||
/** The skeleton's name, which by default is the name of the skeleton data file, if possible. */
|
/** The skeleton's name, which by default is the name of the skeleton data file, if possible. */
|
||||||
@Null
|
public @Null String getName () {
|
||||||
public String getName () {
|
|
||||||
return name;
|
return name;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -273,8 +263,7 @@ public class SkeletonData {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** The Spine version used to export the skeleton data, or null. */
|
/** The Spine version used to export the skeleton data, or null. */
|
||||||
@Null
|
public @Null String getVersion () {
|
||||||
public String getVersion () {
|
|
||||||
return version;
|
return version;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -283,8 +272,7 @@ public class SkeletonData {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** The skeleton data hash. This value will change if any of the skeleton data has changed. */
|
/** The skeleton data hash. This value will change if any of the skeleton data has changed. */
|
||||||
@Null
|
public @Null String getHash () {
|
||||||
public String getHash () {
|
|
||||||
return hash;
|
return hash;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -293,8 +281,7 @@ public class SkeletonData {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** The path to the images directory as defined in Spine. Available only when nonessential data was exported. */
|
/** The path to the images directory as defined in Spine. Available only when nonessential data was exported. */
|
||||||
@Null
|
public @Null String getImagesPath () {
|
||||||
public String getImagesPath () {
|
|
||||||
return imagesPath;
|
return imagesPath;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -303,8 +290,7 @@ public class SkeletonData {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** The path to the audio directory as defined in Spine. Available only when nonessential data was exported. */
|
/** The path to the audio directory as defined in Spine. Available only when nonessential data was exported. */
|
||||||
@Null
|
public @Null String getAudioPath () {
|
||||||
public String getAudioPath () {
|
|
||||||
return audioPath;
|
return audioPath;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -448,8 +448,7 @@ public class SkeletonRenderer {
|
|||||||
this.premultipliedAlpha = premultipliedAlpha;
|
this.premultipliedAlpha = premultipliedAlpha;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Null
|
public @Null VertexEffect getVertexEffect () {
|
||||||
public VertexEffect getVertexEffect () {
|
|
||||||
return vertexEffect;
|
return vertexEffect;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -94,8 +94,7 @@ public class Skin {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** Returns the attachment for the specified slot index and name, or null. */
|
/** Returns the attachment for the specified slot index and name, or null. */
|
||||||
@Null
|
public @Null Attachment getAttachment (int slotIndex, String name) {
|
||||||
public Attachment getAttachment (int slotIndex, String name) {
|
|
||||||
lookup.set(slotIndex, name);
|
lookup.set(slotIndex, name);
|
||||||
SkinEntry entry = attachments.get(lookup);
|
SkinEntry entry = attachments.get(lookup);
|
||||||
return entry != null ? entry.attachment : null;
|
return entry != null ? entry.attachment : null;
|
||||||
|
|||||||
@ -95,14 +95,12 @@ public class Slot {
|
|||||||
|
|
||||||
/** The dark color used to tint the slot's attachment for two color tinting, or null if two color tinting is not used. The dark
|
/** The dark color used to tint the slot's attachment for two color tinting, or null if two color tinting is not used. The dark
|
||||||
* color's alpha is not used. */
|
* color's alpha is not used. */
|
||||||
@Null
|
public @Null Color getDarkColor () {
|
||||||
public Color getDarkColor () {
|
|
||||||
return darkColor;
|
return darkColor;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** The current attachment for the slot, or null if the slot has no attachment. */
|
/** The current attachment for the slot, or null if the slot has no attachment. */
|
||||||
@Null
|
public @Null Attachment getAttachment () {
|
||||||
public Attachment getAttachment () {
|
|
||||||
return attachment;
|
return attachment;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -74,8 +74,7 @@ public class SlotData {
|
|||||||
|
|
||||||
/** The dark color used to tint the slot's attachment for two color tinting, or null if two color tinting is not used. The dark
|
/** The dark color used to tint the slot's attachment for two color tinting, or null if two color tinting is not used. The dark
|
||||||
* color's alpha is not used. */
|
* color's alpha is not used. */
|
||||||
@Null
|
public @Null Color getDarkColor () {
|
||||||
public Color getDarkColor () {
|
|
||||||
return darkColor;
|
return darkColor;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -88,8 +87,7 @@ public class SlotData {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** The name of the attachment that is visible for this slot in the setup pose, or null if no attachment is visible. */
|
/** The name of the attachment that is visible for this slot in the setup pose, or null if no attachment is visible. */
|
||||||
@Null
|
public @Null String getAttachmentName () {
|
||||||
public String getAttachmentName () {
|
|
||||||
return attachmentName;
|
return attachmentName;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -39,26 +39,20 @@ import com.esotericsoftware.spine.Skin;
|
|||||||
* Runtimes Guide. */
|
* Runtimes Guide. */
|
||||||
public interface AttachmentLoader {
|
public interface AttachmentLoader {
|
||||||
/** @return May be null to not load the attachment. */
|
/** @return May be null to not load the attachment. */
|
||||||
@Null
|
public @Null RegionAttachment newRegionAttachment (Skin skin, String name, String path);
|
||||||
public RegionAttachment newRegionAttachment (Skin skin, String name, String path);
|
|
||||||
|
|
||||||
/** @return May be null to not load the attachment. */
|
/** @return May be null to not load the attachment. */
|
||||||
@Null
|
public @Null MeshAttachment newMeshAttachment (Skin skin, String name, String path);
|
||||||
public MeshAttachment newMeshAttachment (Skin skin, String name, String path);
|
|
||||||
|
|
||||||
/** @return May be null to not load the attachment. */
|
/** @return May be null to not load the attachment. */
|
||||||
@Null
|
public @Null BoundingBoxAttachment newBoundingBoxAttachment (Skin skin, String name);
|
||||||
public BoundingBoxAttachment newBoundingBoxAttachment (Skin skin, String name);
|
|
||||||
|
|
||||||
/** @return May be null to not load the attachment. */
|
/** @return May be null to not load the attachment. */
|
||||||
@Null
|
public @Null ClippingAttachment newClippingAttachment (Skin skin, String name);
|
||||||
public ClippingAttachment newClippingAttachment (Skin skin, String name);
|
|
||||||
|
|
||||||
/** @return May be null to not load the attachment. */
|
/** @return May be null to not load the attachment. */
|
||||||
@Null
|
public @Null PathAttachment newPathAttachment (Skin skin, String name);
|
||||||
public PathAttachment newPathAttachment (Skin skin, String name);
|
|
||||||
|
|
||||||
/** @return May be null to not load the attachment. */
|
/** @return May be null to not load the attachment. */
|
||||||
@Null
|
public @Null PointAttachment newPointAttachment (Skin skin, String name);
|
||||||
public PointAttachment newPointAttachment (Skin skin, String name);
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -123,8 +123,7 @@ abstract public class VertexAttachment extends Attachment {
|
|||||||
|
|
||||||
/** Deform keys for the deform attachment are also applied to this attachment.
|
/** Deform keys for the deform attachment are also applied to this attachment.
|
||||||
* @return May be null if no deform keys should be applied. */
|
* @return May be null if no deform keys should be applied. */
|
||||||
@Null
|
public @Null VertexAttachment getDeformAttachment () {
|
||||||
public VertexAttachment getDeformAttachment () {
|
|
||||||
return deformAttachment;
|
return deformAttachment;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -136,8 +135,7 @@ abstract public class VertexAttachment extends Attachment {
|
|||||||
/** The bones which affect the {@link #getVertices()}. The array entries are, for each vertex, the number of bones affecting
|
/** The bones which affect the {@link #getVertices()}. The array entries are, for each vertex, the number of bones affecting
|
||||||
* the vertex followed by that many bone indices, which is the index of the bone in {@link Skeleton#getBones()}. Will be null
|
* the vertex followed by that many bone indices, which is the index of the bone in {@link Skeleton#getBones()}. Will be null
|
||||||
* if this attachment has no weights. */
|
* if this attachment has no weights. */
|
||||||
@Null
|
public @Null int[] getBones () {
|
||||||
public int[] getBones () {
|
|
||||||
return bones;
|
return bones;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user