with GNATCOM.IInterface;

with GNATCOM.Errors;

package body MSHTML.IHTMLTableCell_Interface is

   procedure Initialize (This : in out IHTMLTableCell_Type) is
   begin
      Set_IID (This, IID_IHTMLTableCell);
   end Initialize;

   function Pointer (This : IHTMLTableCell_Type)
     return Pointer_To_IHTMLTableCell
   is
   begin
      return To_Pointer_To_IHTMLTableCell (Address (This));
   end Pointer;

   procedure Attach (This    : in out IHTMLTableCell_Type;
                     Pointer : in     Pointer_To_IHTMLTableCell)
   is
   begin
      Attach (This, GNATCOM.IInterface.To_Pointer_To_IUnknown
              (Pointer.all'Address));
   end Attach;

   procedure Put_rowSpan
     (This : IHTMLTableCell_Type;
      p    : Interfaces.C.long)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_rowSpan
         (Pointer (This),
          p));

   end Put_rowSpan;

   function Get_rowSpan
     (This : IHTMLTableCell_Type)
     return Interfaces.C.long
   is
       RetVal : aliased Interfaces.C.long;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_rowSpan
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_rowSpan;

   procedure Put_colSpan
     (This : IHTMLTableCell_Type;
      p    : Interfaces.C.long)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_colSpan
         (Pointer (This),
          p));

   end Put_colSpan;

   function Get_colSpan
     (This : IHTMLTableCell_Type)
     return Interfaces.C.long
   is
       RetVal : aliased Interfaces.C.long;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_colSpan
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_colSpan;

   procedure Put_align
     (This : IHTMLTableCell_Type;
      p    : GNATCOM.Types.BSTR;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_align
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_align;

   function Get_align
     (This : IHTMLTableCell_Type)
     return GNATCOM.Types.BSTR
   is
       RetVal : aliased GNATCOM.Types.BSTR;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_align
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_align;

   procedure Put_vAlign
     (This : IHTMLTableCell_Type;
      p    : GNATCOM.Types.BSTR;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_vAlign
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_vAlign;

   function Get_vAlign
     (This : IHTMLTableCell_Type)
     return GNATCOM.Types.BSTR
   is
       RetVal : aliased GNATCOM.Types.BSTR;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_vAlign
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_vAlign;

   procedure Put_bgColor
     (This : IHTMLTableCell_Type;
      p    : GNATCOM.Types.VARIANT;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_bgColor
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_bgColor;

   function Get_bgColor
     (This : IHTMLTableCell_Type)
     return GNATCOM.Types.VARIANT
   is
       RetVal : aliased GNATCOM.Types.VARIANT;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_bgColor
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_bgColor;

   procedure Put_noWrap
     (This : IHTMLTableCell_Type;
      p    : GNATCOM.Types.VARIANT_BOOL)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_noWrap
         (Pointer (This),
          p));

   end Put_noWrap;

   function Get_noWrap
     (This : IHTMLTableCell_Type)
     return GNATCOM.Types.VARIANT_BOOL
   is
       RetVal : aliased GNATCOM.Types.VARIANT_BOOL;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_noWrap
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_noWrap;

   procedure Put_background
     (This : IHTMLTableCell_Type;
      p    : GNATCOM.Types.BSTR;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_background
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_background;

   function Get_background
     (This : IHTMLTableCell_Type)
     return GNATCOM.Types.BSTR
   is
       RetVal : aliased GNATCOM.Types.BSTR;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_background
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_background;

   procedure Put_borderColor
     (This : IHTMLTableCell_Type;
      p    : GNATCOM.Types.VARIANT;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_borderColor
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_borderColor;

   function Get_borderColor
     (This : IHTMLTableCell_Type)
     return GNATCOM.Types.VARIANT
   is
       RetVal : aliased GNATCOM.Types.VARIANT;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_borderColor
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_borderColor;

   procedure Put_borderColorLight
     (This : IHTMLTableCell_Type;
      p    : GNATCOM.Types.VARIANT;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_borderColorLight
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_borderColorLight;

   function Get_borderColorLight
     (This : IHTMLTableCell_Type)
     return GNATCOM.Types.VARIANT
   is
       RetVal : aliased GNATCOM.Types.VARIANT;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_borderColorLight
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_borderColorLight;

   procedure Put_borderColorDark
     (This : IHTMLTableCell_Type;
      p    : GNATCOM.Types.VARIANT;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_borderColorDark
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_borderColorDark;

   function Get_borderColorDark
     (This : IHTMLTableCell_Type)
     return GNATCOM.Types.VARIANT
   is
       RetVal : aliased GNATCOM.Types.VARIANT;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_borderColorDark
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_borderColorDark;

   procedure Put_width
     (This : IHTMLTableCell_Type;
      p    : GNATCOM.Types.VARIANT;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_width
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_width;

   function Get_width
     (This : IHTMLTableCell_Type)
     return GNATCOM.Types.VARIANT
   is
       RetVal : aliased GNATCOM.Types.VARIANT;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_width
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_width;

   procedure Put_height
     (This : IHTMLTableCell_Type;
      p    : GNATCOM.Types.VARIANT;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_height
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_height;

   function Get_height
     (This : IHTMLTableCell_Type)
     return GNATCOM.Types.VARIANT
   is
       RetVal : aliased GNATCOM.Types.VARIANT;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_height
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_height;

   function Get_cellIndex
     (This : IHTMLTableCell_Type)
     return Interfaces.C.long
   is
       RetVal : aliased Interfaces.C.long;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_cellIndex
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_cellIndex;

end MSHTML.IHTMLTableCell_Interface;

