collate.h revision 7c478bd95313f5f23a4c958a745db2134aa03244
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (the "License"). You may not use this file except in compliance
* with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright (c) 1996, by Sun Microsystems, Inc.
* All rights reserved.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
/*
*
* Specifically collation information.
*
* Copyright 1989, 1993 by Mortice Kern Systems Inc. All rights reserved.
*
*/
#ifndef __COLLATE_H__
#define __COLLATE_H__
#include <mks.h>
#include <limits.h>
/*
* include prototypes of the MKS i18n routines
*/
#include <m_collat.h>
/*
* constants and structure definitions used in MKS internal implementation
*
* -- used by strxfrm(), localedef.
*/
/* string length limitations */
/* forward, backward... -- or'ed into cmode */
/* flags used in cord.cflag */
#define _M_NOCOLLSTR 0
/* typedef's */
typedef short _m_weight_t;
/* collate database file header */
struct _m_cinfo {
int cnstr; /* number of collate strings */
int cnotom; /* number of one to many maps */
int cnweight; /* Number of weights in cmode */
*range; /* Range table */
*cequiv; /* equiv class table */
};
/* Per character and per collating-sequence structure */
struct _m_cord { /* order */
unsigned char cflag; /* =1, beginning of a collation string */
};
/*l
* The _m_cstr structure is per many-to-one mapping (collating element from...)
* Pointed at by _m_cinfo.cstr, indexed by (m_collel_t - M_CSETSIZE).
* Stored both forwards and backwards to make it easy for strxfrm parsing
* for order_start backward.
*/
struct _m_cstr { /* collating-element */
};
/*l
* Per one-to-many mapping entry. A cweight entry in the _cord structure
* which is negative, will index into this table.
* Pointed at by _m_cinfo.cotom.
*/
struct _m_cotom { /* one to many map */
};
#ifdef I18N
#endif /* I18N */
#endif /* __COLLATE_H_ */