Skip to content

Commit 91d70d7

Browse files
committed
Reorganized source and header files
All header files and their respective source files have been moved under fras/ directories. Relatedly, all code has been moved from the "cfg" namespace to the more unique "fras" namespace.
1 parent 2e15fc0 commit 91d70d7

13 files changed

+62
-61
lines changed
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
#ifndef INCLUDED_CFG_JAGGED_ARRAY
2-
#define INCLUDED_CFG_JAGGED_ARRAY
1+
#ifndef INCLUDED_FRAS_ARRAY_JAGGED_ARRAY
2+
#define INCLUDED_FRAS_ARRAY_JAGGED_ARRAY
33

4-
namespace cfg {
4+
namespace fras {
55

66
/** An abstract class that provides an interface for jagged array implementations. */
77
class JaggedArray
Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
#ifndef INCLUDED_CFG_JAGGED_ARRAY_BP
2-
#define INCLUDED_CFG_JAGGED_ARRAY_BP
1+
#ifndef INCLUDED_FRAS_ARRAY_JAGGED_ARRAY_BP
2+
#define INCLUDED_FRAS_ARRAY_JAGGED_ARRAY_BP
33

4-
#include "cfg/jagged_array.hpp"
4+
#include "fras/array/jagged_array.hpp"
5+
#include <cstdint>
56

6-
namespace cfg {
7+
namespace fras {
78

89
/**
910
* An abstract class that provides an interface for jagged array implementations based on bit packing.

include/cfg/jagged_array_bp_index.hpp renamed to include/fras/array/jagged_array_bp_index.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
#ifndef INCLUDED_CFG_JAGGED_ARRAY_BP_INDEX
2-
#define INCLUDED_CFG_JAGGED_ARRAY_BP_INDEX
1+
#ifndef INCLUDED_FRAS_ARRAY_JAGGED_ARRAY_BP_INDEX
2+
#define INCLUDED_FRAS_ARRAY_JAGGED_ARRAY_BP_INDEX
33

4-
#include "cfg/jagged_array_bp.hpp"
4+
#include "fras/array/jagged_array_bp.hpp"
55

6-
namespace cfg {
6+
namespace fras {
77

88
/**
99
* Implements the JaggedArrayBp abstract class using index-based bit packing.

include/cfg/jagged_array_bp_mono.hpp renamed to include/fras/array/jagged_array_bp_mono.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
#ifndef INCLUDED_CFG_JAGGED_ARRAY_BP_MONO
2-
#define INCLUDED_CFG_JAGGED_ARRAY_BP_MONO
1+
#ifndef INCLUDED_FRAS_ARRAY_JAGGED_ARRAY_BP_MONO
2+
#define INCLUDED_FRAS_ARRAY_JAGGED_ARRAY_BP_MONO
33

44
#include <algorithm>
5-
#include "cfg/jagged_array_bp.hpp"
5+
#include "fras/array/jagged_array_bp.hpp"
66
#include <sdsl/bit_vectors.hpp>
77
#include <sdsl/util.hpp>
88

9-
namespace cfg {
9+
namespace fras {
1010

1111
/**
1212
* Implements the JaggedArrayBp abstract class using a monotonic sequence of

include/cfg/jagged_array_bp_opt.hpp renamed to include/fras/array/jagged_array_bp_opt.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
#ifndef INCLUDED_CFG_JAGGED_ARRAY_BP_OPT
2-
#define INCLUDED_CFG_JAGGED_ARRAY_BP_OPT
1+
#ifndef INCLUDED_FRAS_ARRAY_JAGGED_ARRAY_BP_OPT
2+
#define INCLUDED_FRAS_ARRAY_JAGGED_ARRAY_BP_OPT
33

44
#include <algorithm>
5-
#include "cfg/jagged_array_bp.hpp"
5+
#include "fras/array/jagged_array_bp.hpp"
66
#include <sdsl/bit_vectors.hpp>
77
#include <sdsl/util.hpp>
88

9-
namespace cfg {
9+
namespace fras {
1010

1111
/**
1212
* Implements the JaggedArrayBp abstract class using the optimal packing size
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
#ifndef INCLUDED_CFG_JAGGED_ARRAY_INT
2-
#define INCLUDED_CFG_JAGGED_ARRAY_INT
1+
#ifndef INCLUDED_FRAS_ARRAY_JAGGED_ARRAY_INT
2+
#define INCLUDED_FRAS_ARRAY_JAGGED_ARRAY_INT
33

44
#include <cstddef>
55
#include <cstdlib>
66
#include <malloc.h>
77
#include <new>
8-
#include "cfg/jagged_array.hpp"
8+
#include "fras/array/jagged_array.hpp"
99

10-
namespace cfg {
10+
namespace fras {
1111

1212
/** Implements the jagged array abstract class using int arrays. */
1313
class JaggedArrayInt : public JaggedArray
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
#ifndef INCLUDED_CFG_CFG
2-
#define INCLUDED_CFG_CFG
1+
#ifndef INCLUDED_FRAS_CFG_CFG
2+
#define INCLUDED_FRAS_CFG_CFG
33

44
#include <cstdint>
55
#include <string>
66

7-
namespace cfg {
7+
namespace fras {
88

99
/** Parses different grammar-compressed CFGs into a naive encoding. */
1010
template <class JaggedArray_T>
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
#ifndef INCLUDED_CFG_RANDOM_ACCESS
2-
#define INCLUDED_CFG_RANDOM_ACCESS
1+
#ifndef INCLUDED_FRAS_CFG_RANDOM_ACCESS
2+
#define INCLUDED_FRAS_CFG_RANDOM_ACCESS
33

44
#include <cstdint>
55
#include <ostream>
66
#include <stack>
77

8-
namespace cfg {
8+
namespace fras {
99

1010
/** An abstract class that adds random access support to a CFG. */
1111
template <class CFG_T>
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
#ifndef INCLUDED_CFG_RANDOM_ACCESS_BV
2-
#define INCLUDED_CFG_RANDOM_ACCESS_BV
1+
#ifndef INCLUDED_FRAS_CFG_RANDOM_ACCESS_BV
2+
#define INCLUDED_FRAS_CFG_RANDOM_ACCESS_BV
33

4-
#include "cfg/random_access.hpp"
4+
#include "fras/cfg/random_access.hpp"
55

6-
namespace cfg {
6+
namespace fras {
77

88
/**
99
* Indexes a CFG for random access using a bit vector.
Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
1-
#ifndef INCLUDED_CFG_RANDOM_ACCESS_SD
2-
#define INCLUDED_CFG_RANDOM_ACCESS_SD
1+
#ifndef INCLUDED_FRAS_CFG_RANDOM_ACCESS_SD
2+
#define INCLUDED_FRAS_CFG_RANDOM_ACCESS_SD
33

4-
#include "cfg/random_access.hpp"
5-
#include "cfg/jagged_array_bp_index.hpp"
6-
#include "cfg/jagged_array_bp_mono.hpp"
7-
#include "cfg/jagged_array_int.hpp"
4+
#include "fras/cfg/random_access.hpp"
5+
#include "fras/array/jagged_array_bp_index.hpp"
6+
#include "fras/array/jagged_array_bp_mono.hpp"
7+
#include "fras/array/jagged_array_int.hpp"
88
#include <sdsl/bit_vectors.hpp>
99
#include <sdsl/util.hpp>
1010

11-
namespace cfg {
11+
namespace fras {
1212

1313
/**
1414
* Indexes a CFG for random access using a bit vector.

0 commit comments

Comments
 (0)