Develop and Download Open Source Software

Browse CVS Repository

Contents of /xoonips/AL/itemtype.cc

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.4 - (show annotations) (download) (as text)
Wed May 18 10:00:17 2005 UTC (18 years, 9 months ago) by aga4096
Branch: MAIN
CVS Tags: AL_PORTING, MergePnt_20051116, REL20051226, XOONIPS_RC1, REL20060323, tag20060615, tag20070307current, tag20061115, MergePnt_20051220, tag20061130, merge_to_20060605, tag20070307, REL20060213, RELENG_2_0_0a_RELEASE, tag20060622, merge_to_20060411, HEAD
Branch point for: XOONIPS_STABLE_32, XOONIPS_STABLE, XOONIPS_STABLE_3, XOONIPS_STABLE_2
Changes since 1.3: +11 -1 lines
File MIME type: text/x-c++src
・モジュール統合に対応.

1 /*
2 * --------------------------------------------------------------------------
3 * XooNiPs Xoops modules for Neuroinformatics Platforms
4 * Copyright (C) 2005 RIKEN, Japan. All rights reserved.
5 * http://sourceforge.jp/projects/xoonips/
6 * --------------------------------------------------------------------------
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation; either version 2
10 * of the License, or (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 * --------------------------------------------------------------------------
21 *
22 *
23 * $Revision: 1.3 $
24 * $Log: itemtype.cc,v $
25 * Revision 1.3 2005/03/15 04:49:40 tani
26 * 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申.
27 *
28 * Revision 1.2 2005/01/24 10:51:11 youi
29 * 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申ID鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申.
30 *
31 * Revision 1.1 2005/01/14 04:28:07 youi
32 * initial version
33 *
34 *
35 */
36 #include <string.h>
37
38 #include "common.h"
39 #include "itemtype.h"
40
41
42 itemtype::itemtype()
43 {
44 item_type_id = 0;
45 mid = 0;
46 memset( name, '\0', XNP_ITEMTYPE_NAME_LEN + 1 );
47 memset( display_name, '\0', XNP_ITEMTYPE_DISPLAY_NAME_LEN + 1 );
48 memset( viewphp, '\0', XNP_ITEMTYPE_VIEWPHP_LEN + 1 );
49 }
50
51 itemtype::~itemtype(){}
52
53 itemtypeid_t itemtype::getItemTypeID() const { return item_type_id; }
54 const char* itemtype::getName() const { return name; }
55 const char* itemtype::getDisplayName() const { return display_name; }
56 const char* itemtype::getViewphp() const { return viewphp; }
57 itemtypeid_t itemtype::getModuleID() const { return mid; }
58
59 void itemtype::setItemTypeID( itemtypeid_t x ){ this -> item_type_id = x; }
60 void itemtype::setName( const char* x )
61 {
62 strncpy( this -> name, x, XNP_ITEMTYPE_NAME_LEN );
63 this -> name[ XNP_ITEMTYPE_NAME_LEN ] = '\0';
64 }
65 void itemtype::setDisplayName( const char* x )
66 {
67 strncpy( this -> display_name, x, XNP_ITEMTYPE_DISPLAY_NAME_LEN );
68 this -> display_name[ XNP_ITEMTYPE_DISPLAY_NAME_LEN ] = '\0';
69 }
70 void itemtype::setViewphp( const char* x )
71 {
72 strncpy( this -> viewphp, x, XNP_ITEMTYPE_VIEWPHP_LEN );
73 this -> viewphp[ XNP_ITEMTYPE_VIEWPHP_LEN ] = '\0';
74 }
75 void itemtype::setModuleID( unsigned int x ){ this -> mid = x; }

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26