tools/adflib: Move host version to $(CROSSTOOLS), fix several small bugs
[AROS.git] / compiler / alib / newobject.c
blobcbdd48b0c9d57c5d63af8e0bf4db1bef7f8712e4
1 /*
2 Copyright © 1995-2001, The AROS Development Team. All rights reserved.
3 $Id$
5 Desc: Create a new BOOPSI object
6 Lang: english
7 */
9 #define AROS_TAGRETURNTYPE APTR
11 #include <intuition/classes.h>
12 #include <intuition/intuitionbase.h>
13 #include "alib_intern.h"
15 extern struct IntuitionBase * IntuitionBase;
17 /*****************************************************************************
19 NAME */
20 #include <intuition/classusr.h>
21 #define NO_INLINE_STDARG /* turn off inline def */
22 #include <proto/intuition.h>
24 APTR NewObject (
26 /* SYNOPSIS */
27 struct IClass * classPtr,
28 UBYTE * classID,
29 Tag tag1,
30 ... )
32 /* FUNCTION
33 Use this function to create BOOPSI objects (BOOPSI stands for
34 "Basic Object Oriented Programming System for Intuition).
36 You may specify a class either by it's name (if it's a public class)
37 or by a pointer to its definition (if it's a private class). If
38 classPtr is NULL, classID is used.
40 INPUTS
41 classPtr - Pointer to a private class (or a public class if you
42 happen to have a pointer to it)
43 classID - Name of a public class
44 tagList - Initial attributes. Read the documentation of the class
45 carefully to find out which attributes must be specified
46 here and which can.
48 RESULT
49 A BOOPSI object which can be manipulated with general functions and
50 which must be disposed with DisposeObject() later.
52 NOTES
53 This functions send OM_NEW to the dispatcher of the class.
55 EXAMPLE
57 BUGS
59 SEE ALSO
60 boopsi.library/DisposeObject(), boopsi.library/SetAttrsA(),
61 boopsi.library/GetAttr(), boopsi.library/MakeClass(),
62 "Basic Object-Oriented Programming System for Intuition" and
63 "boopsi Class Reference" Dokument.
65 INTERNALS
67 HISTORY
68 29-10-95 digulla automatically created from
69 intuition_lib.fd and clib/intuition_protos.h
71 *****************************************************************************/
73 AROS_SLOWSTACKTAGS_PRE(tag1)
74 retval = NewObjectA (classPtr, classID, AROS_SLOWSTACKTAGS_ARG(tag1));
75 AROS_SLOWSTACKTAGS_POST
76 } /* NewObject */