home *** CD-ROM | disk | FTP | other *** search
/ Windows 95 v2.4 Fix / W95-v2.4fix.iso / ACADWIN / ADS / CPP / GENERAL / ADSOBJ.CPP < prev    next >
Encoding:
C/C++ Source or Header  |  1995-02-08  |  1.9 KB  |  63 lines

  1. /* 
  2.     ADSOBJ.CPP -
  3.     
  4.     This file:
  5.  
  6.         Defines the principal base class ADS_OBJ for ADS C++
  7.         hierarchy.
  8.         
  9.  
  10.     (C) Copyright 1988-1994 by Autodesk, Inc.
  11.  
  12.     This program is copyrighted by Autodesk, Inc. and is  licensed
  13.     to you under the following conditions.  You may not distribute
  14.     or  publish the source code of this program in any form.   You
  15.     may  incorporate this code in object form in derivative  works
  16.     provided  such  derivative  works  are  (i.) are  designed and
  17.     intended  to  work  solely  with  Autodesk, Inc. products, and
  18.     (ii.)  contain  Autodesk's  copyright  notice  "(C)  Copyright
  19.     1988-1994 by Autodesk, Inc."
  20.  
  21.     AUTODESK  PROVIDES THIS PROGRAM "AS IS" AND WITH  ALL  FAULTS.
  22.     AUTODESK  SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTY OF  MER-
  23.     CHANTABILITY OR FITNESS FOR A PARTICULAR USE.  AUTODESK,  INC.
  24.     DOES  NOT  WARRANT THAT THE OPERATION OF THE PROGRAM  WILL  BE
  25.     UNINTERRUPTED OR ERROR FREE.
  26.  
  27. */
  28. #include "adsinc.h"
  29.  
  30. //-----------------------------------------------------------------------------
  31. #ifdef CPPADS_DBG
  32. static char     dbg_string[256];
  33. #endif
  34.  
  35. //-----------------------------------------------------------------------------
  36. int ADS_OBJ::obj_inited = 0;
  37.  
  38. //-----------------------------------------------------------------------------
  39. ADS_OBJ::ADS_OBJ()
  40. {
  41.     obj_inited++;
  42. #ifdef CPPADS_DBG
  43.     wsprintf( dbg_string
  44.             , " ADS_OBJ ctr: this = %lx, num of ADS_OBJ now: %d\n"
  45.             , this 
  46.             , obj_inited );
  47.     OutputDebugString( dbg_string );
  48. #endif
  49. }
  50.  
  51. //-----------------------------------------------------------------------------
  52. ADS_OBJ::~ADS_OBJ()
  53. {
  54.     obj_inited--;
  55. #ifdef CPPADS_DBG
  56.     wsprintf( dbg_string
  57.             , " ADS_OBJ dtr: this = %lx, num of ADS_OBJ left: %d\n"
  58.             , this 
  59.             , obj_inited );
  60.     OutputDebugString( dbg_string );
  61. #endif
  62. }
  63.