with GNATCOM.IInterface;

with GNATCOM.Errors;

package body MSHTML.IDOMParserFactory_Interface is

   procedure Initialize (This : in out IDOMParserFactory_Type) is
   begin
      Set_IID (This, IID_IDOMParserFactory);
   end Initialize;

   function Pointer (This : IDOMParserFactory_Type)
     return Pointer_To_IDOMParserFactory
   is
   begin
      return To_Pointer_To_IDOMParserFactory (Address (This));
   end Pointer;

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

   function create
     (This                          : IDOMParserFactory_Type)
     return Pointer_To_IDOMParser
   is
       RetVal : aliased Pointer_To_IDOMParser;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.create
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end create;

end MSHTML.IDOMParserFactory_Interface;

