// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*-

#ifndef __javax_swing_text_GapContent__
#define __javax_swing_text_GapContent__

#pragma interface

#include <java/lang/Object.h>
#include <gcj/array.h>

extern "Java"
{
  namespace javax
  {
    namespace swing
    {
      namespace text
      {
        class GapContent;
        class Position;
        class Segment;
      }
      namespace undo
      {
        class UndoableEdit;
      }
    }
  }
}

class javax::swing::text::GapContent : public ::java::lang::Object
{
public:
  GapContent ();
  GapContent (jint);
public:  // actually protected
  virtual ::java::lang::Object *allocateArray (jint);
  virtual jint getArrayLength ();
public:
  virtual jint length ();
  virtual ::javax::swing::undo::UndoableEdit *insertString (jint, ::java::lang::String *);
  virtual ::javax::swing::undo::UndoableEdit *remove (jint, jint);
  virtual ::java::lang::String *getString (jint, jint);
  virtual void getChars (jint, jint, ::javax::swing::text::Segment *);
  virtual ::javax::swing::text::Position *createPosition (jint);
public:  // actually protected
  virtual void shiftEnd (jint);
  virtual void shiftGap (jint);
  virtual void shiftGapStartDown (jint);
  virtual void shiftGapEndUp (jint);
  virtual ::java::lang::Object *getArray () { return reinterpret_cast< ::java::lang::Object *> (buffer); }
  virtual void replace (jint, jint, ::java::lang::Object *, jint);
  virtual jint getGapStart () { return gapStart; }
  virtual jint getGapEnd () { return gapEnd; }
  virtual ::java::util::Vector *getPositionsInRange (::java::util::Vector *, jint, jint);
public: // actually package-private
  virtual void setPositionsInRange (jint, jint, jint);
  virtual void adjustPositionsInRange (jint, jint, jint);
public:  // actually protected
  virtual void resetMarksAtZero ();
private:
  void dump ();
  void dumpPositions ();
  static const jlong serialVersionUID = -6226052713477823730LL;
public: // actually package-private
  static const jint DEFAULT_BUFSIZE = 10L;
  jcharArray __attribute__((aligned(__alignof__( ::java::lang::Object ))))  buffer;
  jint gapStart;
  jint gapEnd;
  ::java::util::ArrayList *positions;
private:
  static jboolean $assertionsDisabled;

  friend class javax_swing_text_GapContent$UndoRemove;
  friend class javax_swing_text_GapContent$UndoInsertString;
  friend class javax_swing_text_GapContent$GapContentPosition;
public:

  static ::java::lang::Class class$;
};

#endif /* __javax_swing_text_GapContent__ */
