License stuff

This commit is contained in:
Steveice10 2012-03-03 10:05:44 -08:00
parent 8748664953
commit 31fcbf3a36
17 changed files with 97 additions and 70 deletions

33
HEADER.txt Normal file
View File

@ -0,0 +1,33 @@
/*
* OpenNBT License
*
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* * Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* * Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* * Neither the name of the JNBT team nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/

View File

@ -3,9 +3,10 @@ package opennbt;
import java.nio.charset.Charset;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -18,7 +19,7 @@ import java.nio.charset.Charset;
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* * Neither the name of the JNBT team nor the names of its
* * Neither the name of the OpenNBT team nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
@ -37,8 +38,6 @@ import java.nio.charset.Charset;
/**
* A class which holds constant values.
* @author Graham Edgecombe
*
*/
public final class NBTConstants {

View File

@ -19,9 +19,10 @@ import opennbt.tag.Tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -34,7 +35,7 @@ import opennbt.tag.Tag;
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* * Neither the name of the JNBT team nor the names of its
* * Neither the name of the OpenNBT team nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
@ -53,8 +54,6 @@ import opennbt.tag.Tag;
/**
* A class which contains NBT-related utility methods.
* @author Graham Edgecombe
*
*/
public final class NBTUtils {
@ -160,6 +159,11 @@ public final class NBTUtils {
}
}
/**
* Clones a <String, Tag> Map.
* @param map to clone
* @return clone of map
*/
public static Map<String, Tag> cloneMap(Map<String, Tag> map) {
Map<String, Tag> newMap = new HashMap<String, Tag>();
@ -170,6 +174,11 @@ public final class NBTUtils {
return newMap;
}
/**
* Clones a byte array
* @param array to clone
* @return clone of array
*/
public static byte[] cloneArray(byte[] array) {
if(array == null) {
return null;

View File

@ -1,9 +1,10 @@
package opennbt.stream;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -16,7 +17,7 @@ package opennbt.stream;
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* * Neither the name of the JNBT team nor the names of its
* * Neither the name of the OpenNBT team nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
@ -67,8 +68,6 @@ import opennbt.tag.Tag;
* <p>The NBT format was created by Markus Persson, and the specification may
* be found at <a href="http://www.minecraft.net/docs/NBT.txt">
* http://www.minecraft.net/docs/NBT.txt</a>.</p>
* @author Graham Edgecombe
*
*/
public final class NBTInputStream implements Closeable {

View File

@ -24,9 +24,10 @@ import opennbt.tag.Tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -39,7 +40,7 @@ import opennbt.tag.Tag;
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* * Neither the name of the JNBT team nor the names of its
* * Neither the name of the OpenNBT team nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
@ -64,8 +65,6 @@ import opennbt.tag.Tag;
* <p>The NBT format was created by Markus Persson, and the specification may
* be found at <a href="http://www.minecraft.net/docs/NBT.txt">
* http://www.minecraft.net/docs/NBT.txt</a>.</p>
* @author Graham Edgecombe
*
*/
public final class NBTOutputStream implements Closeable {

View File

@ -6,9 +6,10 @@ import opennbt.NBTUtils;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -21,7 +22,7 @@ import opennbt.NBTUtils;
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* * Neither the name of the JNBT team nor the names of its
* * Neither the name of the OpenNBT team nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
@ -40,8 +41,6 @@ import opennbt.NBTUtils;
/**
* The <code>TAG_Byte_Array</code> tag.
* @author Graham Edgecombe
*
*/
public final class ByteArrayTag extends Tag {

View File

@ -1,9 +1,10 @@
package opennbt.tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -16,7 +17,7 @@ package opennbt.tag;
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* * Neither the name of the JNBT team nor the names of its
* * Neither the name of the OpenNBT team nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
@ -35,8 +36,6 @@ package opennbt.tag;
/**
* The <code>TAG_Byte</code> tag.
* @author Graham Edgecombe
*
*/
public final class ByteTag extends Tag {

View File

@ -1,9 +1,10 @@
package opennbt.tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -41,8 +42,6 @@ import opennbt.NBTUtils;
/**
* The <code>TAG_Compound</code> tag.
* @author Graham Edgecombe
*
*/
public final class CompoundTag extends Tag {

View File

@ -1,9 +1,10 @@
package opennbt.tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -35,8 +36,6 @@ package opennbt.tag;
/**
* The <code>TAG_Double</code> tag.
* @author Graham Edgecombe
*
*/
public final class DoubleTag extends Tag {

View File

@ -1,9 +1,10 @@
package opennbt.tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -35,8 +36,6 @@ package opennbt.tag;
/**
* The <code>TAG_End</code> tag.
* @author Graham Edgecombe
*
*/
public final class EndTag extends Tag {

View File

@ -1,9 +1,10 @@
package opennbt.tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -35,8 +36,6 @@ package opennbt.tag;
/**
* The <code>TAG_Float</code> tag.
* @author Graham Edgecombe
*
*/
public final class FloatTag extends Tag {

View File

@ -1,9 +1,10 @@
package opennbt.tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -35,8 +36,6 @@ package opennbt.tag;
/**
* The <code>TAG_Int</code> tag.
* @author Graham Edgecombe
*
*/
public final class IntTag extends Tag {

View File

@ -1,9 +1,10 @@
package opennbt.tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -42,8 +43,6 @@ import opennbt.NBTUtils;
/**
* The <code>TAG_List</code> tag.
* @author Graham Edgecombe
*
*/
public final class ListTag<T extends Tag> extends Tag {

View File

@ -1,9 +1,10 @@
package opennbt.tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -35,8 +36,6 @@ package opennbt.tag;
/**
* The <code>TAG_Long</code> tag.
* @author Graham Edgecombe
*
*/
public final class LongTag extends Tag {

View File

@ -1,9 +1,10 @@
package opennbt.tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -35,8 +36,6 @@ package opennbt.tag;
/**
* The <code>TAG_Short</code> tag.
* @author Graham Edgecombe
*
*/
public final class ShortTag extends Tag {

View File

@ -1,9 +1,10 @@
package opennbt.tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -35,8 +36,6 @@ package opennbt.tag;
/**
* The <code>TAG_String</code> tag.
* @author Graham Edgecombe
*
*/
public final class StringTag extends Tag {

View File

@ -1,9 +1,10 @@
package opennbt.tag;
/*
* JNBT License
* OpenNBT License
*
* Copyright (c) 2010 Graham Edgecombe
* JNBT Copyright (c) 2010 Graham Edgecombe
* OpenNBT Copyright(c) 2012 Steveice10
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -35,8 +36,6 @@ package opennbt.tag;
/**
* Represents a single NBT tag.
* @author Graham Edgecombe
*
*/
public abstract class Tag implements Cloneable {