mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-28 18:20:14 +01:00
[tree] Move tree files to Poincare
This commit is contained in:
@@ -5,10 +5,12 @@
|
||||
|
||||
#include <poincare/absolute_value.h>
|
||||
#include <poincare/addition.h>
|
||||
#include <poincare/allocation_failed_layout_node.h>
|
||||
#include <poincare/arc_cosine.h>
|
||||
#include <poincare/arc_sine.h>
|
||||
#include <poincare/arc_tangent.h>
|
||||
#include <poincare/binomial_coefficient.h>
|
||||
#include <poincare/char_layout_node.h>
|
||||
#include <poincare/ceiling.h>
|
||||
#include <poincare/complex.h>
|
||||
#include <poincare/complex_argument.h>
|
||||
@@ -35,6 +37,7 @@
|
||||
#include <poincare/frac_part.h>
|
||||
#include <poincare/global_context.h>
|
||||
#include <poincare/great_common_divisor.h>
|
||||
#include <poincare/horizontal_layout_node.h>
|
||||
#include <poincare/hyperbolic_arc_cosine.h>
|
||||
#include <poincare/hyperbolic_arc_sine.h>
|
||||
#include <poincare/hyperbolic_arc_tangent.h>
|
||||
@@ -43,6 +46,9 @@
|
||||
#include <poincare/hyperbolic_tangent.h>
|
||||
#include <poincare/imaginary_part.h>
|
||||
#include <poincare/integral.h>
|
||||
#include <poincare/layout_cursor.h>
|
||||
#include <poincare/layout_node.h>
|
||||
#include <poincare/layout_reference.h>
|
||||
#include <poincare/least_common_multiple.h>
|
||||
#include <poincare/logarithm.h>
|
||||
#include <poincare/matrix.h>
|
||||
@@ -72,6 +78,9 @@
|
||||
#include <poincare/sum.h>
|
||||
#include <poincare/symbol.h>
|
||||
#include <poincare/tangent.h>
|
||||
#include <poincare/tree_node.h>
|
||||
#include <poincare/tree_pool.h>
|
||||
#include <poincare/tree_reference.h>
|
||||
#include <poincare/undefined.h>
|
||||
#include <poincare/variable_context.h>
|
||||
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
#ifndef ALLOCATION_FAILED_LAYOUT_NODE_H
|
||||
#define ALLOCATION_FAILED_LAYOUT_NODE_H
|
||||
#ifndef POINCARE_ALLOCATION_FAILED_LAYOUT_NODE_H
|
||||
#define POINCARE_ALLOCATION_FAILED_LAYOUT_NODE_H
|
||||
|
||||
#include "layout_node.h"
|
||||
#include "layout_reference.h"
|
||||
|
||||
namespace Poincare {
|
||||
|
||||
class AllocationFailedLayoutNode : public LayoutNode {
|
||||
public:
|
||||
// TreeNode
|
||||
@@ -18,4 +20,6 @@ public:
|
||||
AllocationFailedLayoutRef() : LayoutReference<AllocationFailedLayoutNode>() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,9 +1,11 @@
|
||||
#ifndef CHAR_LAYOUT_H
|
||||
#define CHAR_LAYOUT_H
|
||||
#ifndef POINCARE_CHAR_LAYOUT_NODE_H
|
||||
#define POINCARE_CHAR_LAYOUT_NODE_H
|
||||
|
||||
#include "layout_reference.h"
|
||||
#include "layout_node.h"
|
||||
#include "layout_cursor.h"
|
||||
#include <poincare/layout_reference.h>
|
||||
#include <poincare/layout_node.h>
|
||||
#include <poincare/layout_cursor.h>
|
||||
|
||||
namespace Poincare {
|
||||
|
||||
class CharLayoutNode : public LayoutNode {
|
||||
public:
|
||||
@@ -56,4 +58,6 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,10 +1,12 @@
|
||||
#ifndef HORIZONTAL_LAYOUT_H
|
||||
#define HORIZONTAL_LAYOUT_H
|
||||
#ifndef POINCARE_HORIZONTAL_LAYOUT_NODE_H
|
||||
#define POINCARE_HORIZONTAL_LAYOUT_NODE_H
|
||||
|
||||
#include "layout_reference.h"
|
||||
#include "layout_node.h"
|
||||
#include "layout_cursor.h"
|
||||
|
||||
namespace Poincare {
|
||||
|
||||
class HorizontalLayoutNode : public LayoutNode {
|
||||
public:
|
||||
HorizontalLayoutNode() :
|
||||
@@ -94,4 +96,6 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,10 +1,12 @@
|
||||
#ifndef LAYOUT_CURSOR_H
|
||||
#define LAYOUT_CURSOR_H
|
||||
#ifndef POINCARE_LAYOUT_CURSOR_H
|
||||
#define POINCARE_LAYOUT_CURSOR_H
|
||||
|
||||
#include "layout_reference.h"
|
||||
#include "layout_node.h"
|
||||
#include <stdio.h>
|
||||
|
||||
namespace Poincare {
|
||||
|
||||
class LayoutCursor {
|
||||
template <typename T>
|
||||
friend class LayoutReference;
|
||||
@@ -64,4 +66,6 @@ private:
|
||||
Position m_position;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,8 +1,10 @@
|
||||
#ifndef LAYOUT_NODE_H
|
||||
#define LAYOUT_NODE_H
|
||||
#ifndef POINCARE_LAYOUT_NODE_H
|
||||
#define POINCARE_LAYOUT_NODE_H
|
||||
|
||||
#include "tree_node.h"
|
||||
|
||||
namespace Poincare {
|
||||
|
||||
class LayoutCursor;
|
||||
|
||||
class LayoutNode : public TreeNode {
|
||||
@@ -64,4 +66,6 @@ private:
|
||||
virtual void render() {};
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,9 +1,11 @@
|
||||
#ifndef LAYOUT_REFERENCE_H
|
||||
#define LAYOUT_REFERENCE_H
|
||||
#ifndef POINCARE_LAYOUT_REFERENCE_H
|
||||
#define POINCARE_LAYOUT_REFERENCE_H
|
||||
|
||||
#include "tree_reference.h"
|
||||
#include "layout_node.h"
|
||||
|
||||
namespace Poincare {
|
||||
|
||||
class LayoutCursor;
|
||||
|
||||
template <typename T>
|
||||
@@ -42,4 +44,6 @@ public:
|
||||
|
||||
typedef LayoutReference<LayoutNode> LayoutRef;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,5 +1,5 @@
|
||||
#ifndef TREE_NODE_H
|
||||
#define TREE_NODE_H
|
||||
#ifndef POINCARE_TREE_NODE_H
|
||||
#define POINCARE_TREE_NODE_H
|
||||
|
||||
#include <assert.h>
|
||||
#include <stddef.h>
|
||||
@@ -13,6 +13,8 @@
|
||||
* - a reference counter
|
||||
*/
|
||||
|
||||
namespace Poincare {
|
||||
|
||||
class TreeNode {
|
||||
friend class TreePool;
|
||||
public:
|
||||
@@ -181,4 +183,6 @@ private:
|
||||
int m_referenceCounter;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,11 +1,13 @@
|
||||
#ifndef TREE_POOL_H
|
||||
#define TREE_POOL_H
|
||||
#ifndef POINCARE_TREE_POOL_H
|
||||
#define POINCARE_TREE_POOL_H
|
||||
|
||||
#include "tree_node.h"
|
||||
#include <stddef.h>
|
||||
#include <string.h>
|
||||
#include <new>
|
||||
|
||||
namespace Poincare {
|
||||
|
||||
class TreePool {
|
||||
friend class TreeNode;
|
||||
public:
|
||||
@@ -172,4 +174,6 @@ private:
|
||||
TreeNode * m_staticNodes[MaxNumberOfStaticNodes];
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,9 +1,11 @@
|
||||
#ifndef TREE_REFERENCE_H
|
||||
#define TREE_REFERENCE_H
|
||||
#ifndef POINCARE_TREE_REFERENCE_H
|
||||
#define POINCARE_TREE_REFERENCE_H
|
||||
|
||||
#include "tree_pool.h"
|
||||
#include <stdio.h>
|
||||
|
||||
namespace Poincare {
|
||||
|
||||
static inline int min(int i, int j) { return i < j ? i : j; }
|
||||
static inline int max(int i, int j) { return i > j ? i : j; }
|
||||
|
||||
@@ -245,4 +247,6 @@ private:
|
||||
|
||||
typedef TreeReference<TreeNode> TreeRef;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user