aboutsummaryrefslogtreecommitdiffstats
path: root/searchcore/src/vespa/searchcore/proton/common/document_type_inspector.h
blob: 50591bc897f1486a4c9d1e987b60c82661bd9799 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.

#pragma once

#include "i_document_type_inspector.h"
#include <vespa/document/datatype/documenttype.h>

namespace proton {

/**
 * Inspector of a concrete document type.
 */
class DocumentTypeInspector : public IDocumentTypeInspector
{
private:
    const document::DocumentType &_oldDocType;
    const document::DocumentType &_newDocType;

public:
    DocumentTypeInspector(const document::DocumentType &oldDocType,
                          const document::DocumentType &newDocType);

    virtual bool hasUnchangedField(const vespalib::string &name) const override;
};

} // namespace proton