Clean up includes and forward declarations a bit

This commit is contained in:
Thomas Goyne 2016-04-11 13:24:04 -07:00
parent 155d949793
commit c12d87427a
19 changed files with 25 additions and 47 deletions

View File

@ -23,6 +23,9 @@
#include "util/atomic_shared_ptr.hpp"
#include <exception>
#include <functional>
#include <memory>
#include <vector>
namespace realm {
namespace _impl {

View File

@ -23,8 +23,10 @@
#include <realm/group_shared.hpp>
#include <mutex>
#include <atomic>
#include <exception>
#include <functional>
#include <mutex>
#include <thread>
#include <unordered_map>

View File

@ -18,7 +18,6 @@
#include "impl/list_notifier.hpp"
#include "impl/realm_coordinator.hpp"
#include "shared_realm.hpp"
#include <realm/link_view.hpp>

View File

@ -28,9 +28,8 @@
#include <realm/commit_log.hpp>
#include <realm/group_shared.hpp>
#include <realm/lang_bind_helper.hpp>
#include <realm/string_data.hpp>
#include <cassert>
#include <set>
#include <unordered_map>
using namespace realm;

View File

@ -19,25 +19,19 @@
#ifndef REALM_COORDINATOR_HPP
#define REALM_COORDINATOR_HPP
#include "index_set.hpp"
#include "shared_realm.hpp"
#include <realm/string_data.hpp>
#include <map>
#include <mutex>
namespace realm {
class Replication;
class Results;
class Schema;
class SharedGroup;
class Table;
struct CollectionChangeIndices;
class StringData;
namespace _impl {
class BackgroundCollection;
class ExternalCommitHelper;
class ListNotifier;
class WeakRealmNotifier;
// RealmCoordinator manages the weak cache of Realm instances and communication

View File

@ -18,7 +18,6 @@
#include "impl/results_notifier.hpp"
#include "impl/realm_coordinator.hpp"
#include "results.hpp"
using namespace realm;

View File

@ -24,13 +24,8 @@
#include <realm/group_shared.hpp>
#include <mutex>
#include <functional>
namespace realm {
namespace _impl {
struct TransactionChangeInfo;
class ResultsNotifier : public BackgroundCollection {
public:
ResultsNotifier(Results& target);

View File

@ -20,8 +20,8 @@
#include "binding_context.hpp"
#include "impl/background_collection.hpp"
#include "index_set.hpp"
#include <realm/commit_log.hpp>
#include <realm/group_shared.hpp>
#include <realm/lang_bind_helper.hpp>

View File

@ -21,11 +21,8 @@
#include <realm/group_shared.hpp>
#include "index_set.hpp"
namespace realm {
class BindingContext;
class SharedGroup;
namespace _impl {
struct TransactionChangeInfo;

View File

@ -19,14 +19,15 @@
#ifndef REALM_INDEX_SET_HPP
#define REALM_INDEX_SET_HPP
#include <cstddef>
#include <cstdlib>
#include <initializer_list>
#include <iterator>
#include <type_traits>
#include <utility>
#include <vector>
#include <stddef.h>
namespace realm {
class IndexSet;
namespace _impl {
template<typename OuterIterator>
class MutableChunkedRangeVectorIterator;

View File

@ -22,6 +22,7 @@
#include "impl/realm_coordinator.hpp"
#include "results.hpp"
#include <realm/link_view.hpp>
#include <realm/util/to_string.hpp>
#include <stdexcept>

View File

@ -21,15 +21,17 @@
#include "collection_notifications.hpp"
#include <realm/link_view.hpp>
#include <realm/link_view_fwd.hpp>
#include <realm/row.hpp>
#include <functional>
#include <memory>
namespace realm {
template<typename T> class BasicRowExpr;
using RowExpr = BasicRowExpr<Table>;
class ObjectSchema;
class Query;
class Realm;
class Results;
struct SortOrder;

View File

@ -25,7 +25,7 @@
#include "schema.hpp"
#include "shared_realm.hpp"
#include <string>
#include <realm/link_view.hpp>
namespace realm {

View File

@ -22,14 +22,12 @@
#include "schema.hpp"
#include "property.hpp"
#include <realm/table_ref.hpp>
#include <functional>
#include <realm/group.hpp>
#include <realm/link_view.hpp>
#include <sstream>
namespace realm {
class Group;
class ObjectSchemaValidationException;
class Schema;

View File

@ -23,7 +23,6 @@
#include "shared_realm.hpp"
#include <realm/table_view.hpp>
#include <realm/table.hpp>
#include <realm/util/optional.hpp>
#include <realm/util/to_string.hpp>
@ -31,7 +30,6 @@ namespace realm {
template<typename T> class BasicRowExpr;
using RowExpr = BasicRowExpr<Table>;
class Mixed;
class Results;
class ObjectSchema;
namespace _impl {

View File

@ -18,10 +18,11 @@
#include "schema.hpp"
#include "object_schema.hpp"
#include "object_store.hpp"
#include "property.hpp"
#include <algorithm>
using namespace realm;
static bool compare_by_name(ObjectSchema const& lft, ObjectSchema const& rgt) {

View File

@ -20,14 +20,11 @@
#define REALM_SCHEMA_HPP
#include "object_schema.hpp"
#include "property.hpp"
#include <string>
#include <vector>
namespace realm {
class ObjectSchema;
class Schema : private std::vector<ObjectSchema> {
private:
using base = std::vector<ObjectSchema>;

View File

@ -19,7 +19,6 @@
#include "shared_realm.hpp"
#include "binding_context.hpp"
#include "impl/external_commit_helper.hpp"
#include "impl/realm_coordinator.hpp"
#include "impl/transact_log_handler.hpp"
#include "object_store.hpp"
@ -28,8 +27,6 @@
#include <realm/commit_log.hpp>
#include <realm/group_shared.hpp>
#include <mutex>
using namespace realm;
using namespace realm::_impl;

View File

@ -21,20 +21,15 @@
#include "schema.hpp"
#include <realm/handover_defs.hpp>
#include <memory>
#include <mutex>
#include <string>
#include <thread>
#include <vector>
#include <mutex>
namespace realm {
class BindingContext;
class Group;
class Realm;
class RealmDelegate;
class Replication;
class SharedGroup;
typedef std::shared_ptr<Realm> SharedRealm;