~gabriel1984sibiu/boost/icu

« back to all changes in this revision

Viewing changes to source/test/perf/usetperf/bitset.h

  • Committer: Grevutiu Gabriel
  • Date: 2017-05-02 14:38:27 UTC
  • Revision ID: gabriel1984sibiu@gmail.com-20170502143827-2om3uz0f8prw6nvc
initial source code

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
**********************************************************************
 
3
* Copyright (c) 2002-2005, International Business Machines
 
4
* Corporation and others.  All Rights Reserved.
 
5
**********************************************************************
 
6
* 2002-09-20 aliu Created.
 
7
*/
 
8
#ifndef __BITSET_H__
 
9
#define __BITSET_H__
 
10
 
 
11
#include "unicode/utypes.h"
 
12
 
 
13
/**
 
14
 * A simple, limited clone of the java.util.BitSet.
 
15
 */
 
16
class BitSet {
 
17
 
 
18
    uint32_t len;
 
19
    int32_t* data;
 
20
 
 
21
    void ensureCapacity(uint32_t minLen);
 
22
 
 
23
public:
 
24
 
 
25
    BitSet();
 
26
    ~BitSet();
 
27
 
 
28
    UBool get(int32_t bitIndex) const;
 
29
 
 
30
    void set(int32_t bitIndex);
 
31
 
 
32
    // Non-java
 
33
    void clearAll();
 
34
 
 
35
    // TODO add other methods as needed.
 
36
};
 
37
 
 
38
#endif