Created
July 24, 2010 08:04
-
-
Save frsyuki/488514 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.msgpack; | |
import java.util.List; | |
import java.util.Set; | |
import java.util.Map; | |
public abstract class MessagePackObject { | |
public boolean isNull() { | |
return false; | |
} | |
public boolean asBoolean() { | |
throw new MessageTypeException("type error"); | |
} | |
public byte asByte() { | |
throw new MessageTypeException("type error"); | |
} | |
public int asInt() { | |
throw new MessageTypeException("type error"); | |
} | |
public short asShort() { | |
throw new MessageTypeException("type error"); | |
} | |
public long asLong() { | |
throw new MessageTypeException("type error"); | |
} | |
public float asFloat() { | |
throw new MessageTypeException("type error"); | |
} | |
public double asDouble() { | |
throw new MessageTypeException("type error"); | |
} | |
public byte[] asByteArray() { | |
throw new MessageTypeException("type error"); | |
} | |
public String asString() { | |
throw new MessageTypeException("type error"); | |
} | |
public MessagePackObject[] asArray() { | |
throw new MessageTypeException("type error"); | |
} | |
public List<MessagePackObject> asList() { | |
throw new MessageTypeException("type error"); | |
} | |
public Map<MessagePackObject,MessagePackObject> asMap() { | |
throw new MessageTypeException("type error"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment