Skip to content

Commit

Permalink
add docID to CBL c4doc
Browse files Browse the repository at this point in the history
  • Loading branch information
velicuvlad committed Oct 23, 2024
1 parent 1a3d2db commit 91a04ae
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
5 changes: 4 additions & 1 deletion Objective-C/Internal/CBLC4Document.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// CBLC4Document.h
// CouchbaseLite
//
// Copyright (c) 2017 Couchbase, Inc All rights reserved.
// Copyright (c) 2024 Couchbase, Inc All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -32,6 +32,9 @@ NS_ASSUME_NONNULL_BEGIN
/** Sequence of the selected revision. */
@property (readonly, nonatomic) C4SequenceNumber sequence;

/** Document ID of the selected revision. */
@property (readonly, nonatomic) C4String docID;

/** Revision ID of the selected revision. */
@property (readonly, nonatomic) C4String revID;

Expand Down
6 changes: 5 additions & 1 deletion Objective-C/Internal/CBLC4Document.mm
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// CBLC4Document.mm
// CouchbaseLite
//
// Copyright (c) 2017 Couchbase, Inc All rights reserved.
// Copyright (c) 2024 Couchbase, Inc All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -49,6 +49,10 @@ - (C4SequenceNumber) sequence {
return _rawDoc->selectedRev.sequence;
}

- (C4String) docID {
return _rawDoc->docID;
}

- (C4String) revID {
return _rawDoc->selectedRev.revID;
}
Expand Down

0 comments on commit 91a04ae

Please sign in to comment.