-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2b10cab
commit ac77d2f
Showing
7 changed files
with
135 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
// | ||
// Created by Cheryl Lin on 2024-11-13. | ||
// | ||
|
||
#ifndef FIREBASE_PIPELINE_H | ||
#define FIREBASE_PIPELINE_H | ||
|
||
#include <vector> | ||
#include "Firestore/core/src/called_by_swift/include/pipeline_result.h" | ||
|
||
namespace firebase { | ||
namespace firestore { | ||
namespace core { | ||
class Pipeline { | ||
public: | ||
Pipeline(); | ||
|
||
std::vector<PipelineResult> execute(); | ||
}; | ||
} // namespace core | ||
} // namespace firestore | ||
} // namespace firebase | ||
|
||
#endif // FIREBASE_PIPELINE_H |
32 changes: 32 additions & 0 deletions
32
Firestore/core/src/called_by_swift/include/pipeline_result.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
|
||
|
||
#include <string> | ||
#include <unordered_map> | ||
#include <vector> | ||
#include "Firestore/core/include/firebase/firestore/timestamp.h" | ||
#include "Firestore/core/src/api/api_fwd.h" | ||
|
||
namespace firebase { | ||
namespace firestore { | ||
|
||
namespace model { | ||
class FieldPath; | ||
class FieldValue; | ||
} // namespace model | ||
|
||
namespace core { | ||
|
||
class PipelineResult { | ||
public: | ||
PipelineResult(); | ||
|
||
Timestamp getCreateTime() const; | ||
|
||
std::unordered_map<std::string, model::FieldValue> getData() const; | ||
|
||
api::DocumentReference getReference() const; | ||
}; | ||
} // namespace core | ||
|
||
} // namespace firestore | ||
} // namespace firebase |
39 changes: 39 additions & 0 deletions
39
Firestore/core/src/called_by_swift/include/pipeline_source.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
/* | ||
* Copyright 2024 LLC | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
#include <string> | ||
#include <vector> | ||
|
||
#include "Firestore/core/src/api/api_fwd.h" | ||
#include "Firestore/core/src/called_by_swift/include/pipeline.h" | ||
|
||
namespace firebase { | ||
namespace firestore { | ||
namespace core { | ||
class PipelineSource { | ||
public: | ||
explicit PipelineSource(); | ||
|
||
// Creates a new Pipeline that operates on the specified Firestore collection. | ||
Pipeline GetCollection(const std::string collection_path); | ||
|
||
// Creates a new Pipeline that operates on a specific set of Firestore | ||
// documents. | ||
Pipeline GetDocuments(const std::vector<api::DocumentReference> docs); | ||
}; | ||
} // namespace core | ||
} // namespace firestore | ||
} // namespace firebase |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
|
||
#include "Firestore/core/src/called_by_swift/include/pipeline.h" | ||
namespace firebase { | ||
namespace firestore { | ||
namespace core { | ||
Pipeline::Pipeline() { | ||
} | ||
|
||
} // namespace core | ||
} // namespace firestore | ||
} // namespace firebase |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
/* | ||
* Copyright 2024 LLC | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
#include "Firestore/core/src/called_by_swift/include/pipeline_source.h" | ||
|
||
PipelineSource::PipelineSource() { | ||
} | ||
|
||
Pipeline PipelineSource::GetCollection(const std::string collection_path) { | ||
} | ||
|
||
Pipeline PipelineSource::GetDocuments( | ||
const std::vector<DocumentReference> docs) { | ||
} |