public void updateDocument()

in indexer-core/src/main/java/org/apache/maven/index/creator/MinimalArtifactInfoIndexCreator.java [283:329]


    public void updateDocument(ArtifactInfo ai, Document doc) {
        String info = ArtifactInfo.nvl(ai.getPackaging())
                + ArtifactInfo.FS
                + ai.getLastModified()
                + ArtifactInfo.FS
                + ai.getSize()
                + ArtifactInfo.FS
                + ai.getSourcesExists().toString()
                + ArtifactInfo.FS
                + ai.getJavadocExists().toString()
                + ArtifactInfo.FS
                + ai.getSignatureExists().toString()
                + ArtifactInfo.FS
                + ai.getFileExtension();

        doc.add(FLD_INFO.toField(info));

        doc.add(FLD_GROUP_ID_KW.toField(ai.getGroupId()));
        doc.add(FLD_ARTIFACT_ID_KW.toField(ai.getArtifactId()));
        doc.add(FLD_VERSION_KW.toField(ai.getVersion()));

        // V3
        doc.add(FLD_GROUP_ID.toField(ai.getGroupId()));
        doc.add(FLD_ARTIFACT_ID.toField(ai.getArtifactId()));
        doc.add(FLD_VERSION.toField(ai.getVersion()));
        doc.add(FLD_EXTENSION.toField(ai.getFileExtension()));

        if (ai.getName() != null) {
            doc.add(FLD_NAME.toField(ai.getName()));
        }

        if (ai.getDescription() != null) {
            doc.add(FLD_DESCRIPTION.toField(ai.getDescription()));
        }

        if (ai.getPackaging() != null) {
            doc.add(FLD_PACKAGING.toField(ai.getPackaging()));
        }

        if (ai.getClassifier() != null) {
            doc.add(FLD_CLASSIFIER.toField(ai.getClassifier()));
        }

        if (ai.getSha1() != null) {
            doc.add(FLD_SHA1.toField(ai.getSha1()));
        }
    }