source: vscpl/src/hu/varadiistvan/scpl/io/hgccwrapper

Last change on this file was 6:53519b47b166, checked in by István Váradi <ivaradi@…>, 12 years ago

Imported some further stuff from the IO code

  • Property exe set to *
File size: 3.4 KB
Line 
1#!/bin/sh
2
3# Create a skeleton of a wrapper header for a certain class
4
5classname=$1
6uppername=`echo ${classname} | tr a-z A-Z`
7
8cat > "${classname}.h" <<EOF
9// Copyright (c) 2013 by István Váradi
10
11// This file is part of VSCPL, a simple cross-platform utility library
12
13// Redistribution and use in source and binary forms, with or without
14// modification, are permitted provided that the following conditions are met:
15
16// 1. Redistributions of source code must retain the above copyright notice, this
17// list of conditions and the following disclaimer.
18// 2. Redistributions in binary form must reproduce the above copyright notice,
19// this list of conditions and the following disclaimer in the documentation
20// and/or other materials provided with the distribution.
21
22// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
23// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
24// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
25// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
26// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
27// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
28// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
29// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
30// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
31// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32
33// The views and conclusions contained in the software and documentation are those
34// of the authors and should not be interpreted as representing official policies,
35// either expressed or implied, of the FreeBSD Project.
36
37#ifndef HU_VARADIISTVAN_SCPL_IO_${uppername}_H
38#define HU_VARADIISTVAN_SCPL_IO_${uppername}_H
39//------------------------------------------------------------------------------
40
41#if 0 // The public interface of ${classname}
42
43//------------------------------------------------------------------------------
44
45namespace hu { namespace varadiistvan { namespace scpl { namespace io {
46
47//------------------------------------------------------------------------------
48
49class ${classname}
50{
51public:
52};
53
54//------------------------------------------------------------------------------
55
56} /* namespace hu::varadiistvan::scpl::io */ } /* namespace hu::varadiistvan::scpl */ } /* namespace hu::varadiistvan */ } /* namespace hu */
57
58//------------------------------------------------------------------------------
59
60#endif // 0, The public interface of ${classname}
61
62//------------------------------------------------------------------------------
63
64#include "hu/varadiistvan/scpl/config.h"
65
66//------------------------------------------------------------------------------
67
68#if TARGET_API_POSIX
69
70#include "_posix/${classname}.h"
71
72//------------------------------------------------------------------------------
73
74#elif TARGET_API_WIN32 || TARGET_API_WIN64
75
76#include "_win32/${classname}.h"
77
78//------------------------------------------------------------------------------
79
80#else
81
82#error "Not implemented for this target!"
83
84#endif
85
86//------------------------------------------------------------------------------
87#endif // HU_VARADIISTVAN_SCPL_${uppername}_H
88
89// Local Variables:
90// mode: C++
91// c-basic-offset: 4
92// indent-tabs-mode: nil
93// End:
94EOF
95
96hg add "${classname}.h"
Note: See TracBrowser for help on using the repository browser.