doc method

DocumentReference doc(
  1. String documentPath
)

Gets a DocumentReference for the specified Firestore path.

Implementation

DocumentReference doc(String documentPath) {
  assert(
      documentPath.isNotEmpty, 'a document path must be a non-empty string');
  assert(!documentPath.contains('//'),
      'a collection path must not contain "//"');
  assert(isValidDocumentPath(documentPath),
      'a document path must point to a valid document.');

  return DocumentReference._(this, _delegate.doc(documentPath));
}