Initial import of the CDE 2.1.30 sources from the Open Group.
This commit is contained in:
36
cde/programs/nsgmls/Priority.h
Normal file
36
cde/programs/nsgmls/Priority.h
Normal file
@@ -0,0 +1,36 @@
|
||||
/* $XConsortium: Priority.h /main/1 1996/07/29 17:02:03 cde-hp $ */
|
||||
// Copyright (c) 1994 James Clark
|
||||
// See the file COPYING for copying permission.
|
||||
|
||||
#ifndef Priority_INCLUDED
|
||||
#define Priority_INCLUDED 1
|
||||
|
||||
#include <limits.h>
|
||||
#include "Boolean.h"
|
||||
|
||||
#ifdef SP_NAMESPACE
|
||||
namespace SP_NAMESPACE {
|
||||
#endif
|
||||
|
||||
class Priority {
|
||||
public:
|
||||
typedef unsigned char Type;
|
||||
enum {
|
||||
data = 0,
|
||||
function = 1,
|
||||
delim = UCHAR_MAX
|
||||
};
|
||||
static inline Type blank(int n) {
|
||||
// `Priority::' works round gcc 2.5.5 bug
|
||||
return Priority::Type(n + 1);
|
||||
}
|
||||
static inline Boolean isBlank(Type t) {
|
||||
return function < t && t < delim;
|
||||
}
|
||||
};
|
||||
|
||||
#ifdef SP_NAMESPACE
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* not Priority_INCLUDED */
|
||||
Reference in New Issue
Block a user