⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 vectors.mco

📁 PB 熟悉的哥们希望大家可以互相学习一下
💻 MCO
字号:
/************************************************************
 *                                                          *
 * Copyright (c) 2001-2007 McObject LLC. All Right Reserved.*
 *                                                          *
 ************************************************************/

#define int1                signed<1>
#define int2                signed<2>
#define int4                signed<4>
#define uint4       unsigned<4>
#define uint2       unsigned<2>
#define uint1       unsigned<1>

declare database    vectors;

// This sample demonstrates vectors and indexes based on vectors

struct Item
{
	uint4     id;
	string    name;
};

class Box
{
	string  name;
	uint4   volume;

	vector< string >   owners;					  // history of the box owners
	vector< uint4 >    repairYears;				  // history of the box repairs
	vector< uint2 >    colors;					  // all outside colors
	vector< char<5> >  zipcodes;				  // history of the box locations

	vector< Item >     items;					  // things in the box

	tree< owners, name >      I_owners;			  // owner and name of the box sorted
	tree< repairYears  >      I_ryears;
	tree< colors >            I_colors;
	tree< zipcodes >          I_zipcodes;
	tree< items.name, name >  I_items;			  // ordered by item name, box name

};

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -