realm-js/src/RJSArray.hpp

25 lines
608 B
C++
Raw Normal View History

2015-08-13 09:12:48 -07:00
//
// RJSArray.h
// RealmJS
//
// Created by Ari Lazier on 7/21/15.
// Copyright (c) 2015 Realm. All rights reserved.
//
#import "RJSUtil.hpp"
#import "shared_realm.hpp"
#import <realm/link_view.hpp>
namespace realm {
struct ObjectArray {
ObjectArray(SharedRealm &r, ObjectSchema &s, LinkViewRef l) : realm(r), object_schema(s), link_view(l) {}
// FIXME - all should be const
SharedRealm realm;
ObjectSchema &object_schema;
LinkViewRef link_view;
};
}
JSClassRef RJSArrayClass();
JSObjectRef RJSArrayCreate(JSContextRef ctx, realm::ObjectArray *array);