パッケージ org.postgresql.geometric

クラス PGbox

java.lang.Object
org.postgresql.util.PGobject
org.postgresql.geometric.PGbox
すべての実装されたインタフェース:
Serializable, Cloneable, PGBinaryObject

public class PGbox extends PGobject implements PGBinaryObject, Serializable, Cloneable
This represents the box datatype within org.postgresql.
関連項目:
  • フィールドの概要

    フィールド
    修飾子とタイプ
    フィールド
    説明
    PGpoint @Nullable []
    These are the two points.

    クラスから継承されたフィールド org.postgresql.util.PGobject

    type, value
  • コンストラクタの概要

    コンストラクタ
    コンストラクタ
    説明
    Required constructor.
    PGbox(double x1, double y1, double x2, double y2)
     
     
     
  • メソッドの概要

    修飾子とタイプ
    メソッド
    説明
    This must be overridden to allow the object to be cloned.
    boolean
    equals(@Nullable Object obj)
    This must be overridden to allow comparisons of objects.
    @Nullable String
    This must be overridden, to return the value of the object, in the form required by org.postgresql.
    int
    Compute hash.
    int
    This method is called to return the number of bytes needed to store this object in the binary form required by org.postgresql.
    void
    setByteValue(byte[] b, int offset)
    This method is called to set the value of this object.
    void
    setValue(@Nullable String value)
    This method sets the value of this object.
    void
    toBytes(byte[] bytes, int offset)
    This method is called the to store the value of the object, in the binary form required by org.postgresql.

    クラスから継承されたメソッド org.postgresql.util.PGobject

    equals, getType, isNull, setType, toString

    クラスから継承されたメソッド java.lang.Object

    finalize, getClass, notify, notifyAll, wait, wait, wait
  • フィールド詳細

    • point

      public PGpoint @Nullable [] point
      These are the two points.
  • コンストラクタの詳細

    • PGbox

      public PGbox(double x1, double y1, double x2, double y2)
      パラメータ:
      x1 - first x coordinate
      y1 - first y coordinate
      x2 - second x coordinate
      y2 - second y coordinate
    • PGbox

      public PGbox(PGpoint p1, PGpoint p2)
      パラメータ:
      p1 - first point
      p2 - second point
    • PGbox

      public PGbox(String s) throws SQLException
      パラメータ:
      s - Box definition in PostgreSQL syntax
      例外:
      SQLException - if definition is invalid
    • PGbox

      public PGbox()
      Required constructor.
  • メソッドの詳細

    • setValue

      public void setValue(@Nullable String value) throws SQLException
      This method sets the value of this object. It should be overridden, but still called by subclasses.
      オーバーライド:
      setValue クラス内 PGobject
      パラメータ:
      value - a string representation of the value of the object
      例外:
      SQLException - thrown if value is invalid for this type
    • setByteValue

      public void setByteValue(byte[] b, int offset)
      インタフェースからコピーされた説明: PGBinaryObject
      This method is called to set the value of this object.
      定義:
      setByteValue インタフェース内 PGBinaryObject
      パラメータ:
      b - Definition of this point in PostgreSQL's binary syntax
      offset - the offset in the byte array where object data starts
    • equals

      public boolean equals(@Nullable Object obj)
      クラスからコピーされた説明: PGobject
      This must be overridden to allow comparisons of objects.
      オーバーライド:
      equals クラス内 PGobject
      パラメータ:
      obj - Object to compare with
      戻り値:
      true if the two boxes are identical
    • hashCode

      public int hashCode()
      クラスからコピーされた説明: PGobject
      Compute hash. As equals() use only value. Return the same hash for the same value.
      オーバーライド:
      hashCode クラス内 PGobject
      戻り値:
      Value hashcode, 0 if value is null Objects.hashCode(Object)
    • clone

      public Object clone() throws CloneNotSupportedException
      クラスからコピーされた説明: PGobject
      This must be overridden to allow the object to be cloned.
      オーバーライド:
      clone クラス内 PGobject
      例外:
      CloneNotSupportedException
    • getValue

      public @Nullable String getValue()
      クラスからコピーされた説明: PGobject
      This must be overridden, to return the value of the object, in the form required by org.postgresql.
      オーバーライド:
      getValue クラス内 PGobject
      戻り値:
      the PGbox in the syntax expected by org.postgresql
    • lengthInBytes

      public int lengthInBytes()
      インタフェースからコピーされた説明: PGBinaryObject
      This method is called to return the number of bytes needed to store this object in the binary form required by org.postgresql.
      定義:
      lengthInBytes インタフェース内 PGBinaryObject
      戻り値:
      the number of bytes needed to store this object
    • toBytes

      public void toBytes(byte[] bytes, int offset)
      インタフェースからコピーされた説明: PGBinaryObject
      This method is called the to store the value of the object, in the binary form required by org.postgresql.
      定義:
      toBytes インタフェース内 PGBinaryObject
      パラメータ:
      bytes - the array to store the value, it is guaranteed to be at lest PGBinaryObject.lengthInBytes() in size.
      offset - the offset in the byte array where object must be stored