io.grafeas.v1.NoteKind Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of grafeas Show documentation
Show all versions of grafeas Show documentation
Java idiomatic client for Grafeas.
The newest version!
/*
* Copyright 2024 The Grafeas Authors. 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.
* You may obtain a copy of the License at
*
* https://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.
*/
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: grafeas/v1/common.proto
// Protobuf Java Version: 3.25.5
package io.grafeas.v1;
/**
*
*
*
* Kind represents the kinds of notes supported.
*
*
* Protobuf enum {@code grafeas.v1.NoteKind}
*/
public enum NoteKind implements com.google.protobuf.ProtocolMessageEnum {
/**
*
*
*
* Default value. This value is unused.
*
*
* NOTE_KIND_UNSPECIFIED = 0;
*/
NOTE_KIND_UNSPECIFIED(0),
/**
*
*
*
* The note and occurrence represent a package vulnerability.
*
*
* VULNERABILITY = 1;
*/
VULNERABILITY(1),
/**
*
*
*
* The note and occurrence assert build provenance.
*
*
* BUILD = 2;
*/
BUILD(2),
/**
*
*
*
* This represents an image basis relationship.
*
*
* IMAGE = 3;
*/
IMAGE(3),
/**
*
*
*
* This represents a package installed via a package manager.
*
*
* PACKAGE = 4;
*/
PACKAGE(4),
/**
*
*
*
* The note and occurrence track deployment events.
*
*
* DEPLOYMENT = 5;
*/
DEPLOYMENT(5),
/**
*
*
*
* The note and occurrence track the initial discovery status of a resource.
*
*
* DISCOVERY = 6;
*/
DISCOVERY(6),
/**
*
*
*
* This represents a logical "role" that can attest to artifacts.
*
*
* ATTESTATION = 7;
*/
ATTESTATION(7),
/**
*
*
*
* This represents an available package upgrade.
*
*
* UPGRADE = 8;
*/
UPGRADE(8),
/**
*
*
*
* This represents a Compliance Note
*
*
* COMPLIANCE = 9;
*/
COMPLIANCE(9),
/**
*
*
*
* This represents a DSSE attestation Note
*
*
* DSSE_ATTESTATION = 10;
*/
DSSE_ATTESTATION(10),
/**
*
*
*
* This represents a Vulnerability Assessment.
*
*
* VULNERABILITY_ASSESSMENT = 11;
*/
VULNERABILITY_ASSESSMENT(11),
/**
*
*
*
* This represents an SBOM Reference.
*
*
* SBOM_REFERENCE = 12;
*/
SBOM_REFERENCE(12),
UNRECOGNIZED(-1),
;
/**
*
*
*
* Default value. This value is unused.
*
*
* NOTE_KIND_UNSPECIFIED = 0;
*/
public static final int NOTE_KIND_UNSPECIFIED_VALUE = 0;
/**
*
*
*
* The note and occurrence represent a package vulnerability.
*
*
* VULNERABILITY = 1;
*/
public static final int VULNERABILITY_VALUE = 1;
/**
*
*
*
* The note and occurrence assert build provenance.
*
*
* BUILD = 2;
*/
public static final int BUILD_VALUE = 2;
/**
*
*
*
* This represents an image basis relationship.
*
*
* IMAGE = 3;
*/
public static final int IMAGE_VALUE = 3;
/**
*
*
*
* This represents a package installed via a package manager.
*
*
* PACKAGE = 4;
*/
public static final int PACKAGE_VALUE = 4;
/**
*
*
*
* The note and occurrence track deployment events.
*
*
* DEPLOYMENT = 5;
*/
public static final int DEPLOYMENT_VALUE = 5;
/**
*
*
*
* The note and occurrence track the initial discovery status of a resource.
*
*
* DISCOVERY = 6;
*/
public static final int DISCOVERY_VALUE = 6;
/**
*
*
*
* This represents a logical "role" that can attest to artifacts.
*
*
* ATTESTATION = 7;
*/
public static final int ATTESTATION_VALUE = 7;
/**
*
*
*
* This represents an available package upgrade.
*
*
* UPGRADE = 8;
*/
public static final int UPGRADE_VALUE = 8;
/**
*
*
*
* This represents a Compliance Note
*
*
* COMPLIANCE = 9;
*/
public static final int COMPLIANCE_VALUE = 9;
/**
*
*
*
* This represents a DSSE attestation Note
*
*
* DSSE_ATTESTATION = 10;
*/
public static final int DSSE_ATTESTATION_VALUE = 10;
/**
*
*
*
* This represents a Vulnerability Assessment.
*
*
* VULNERABILITY_ASSESSMENT = 11;
*/
public static final int VULNERABILITY_ASSESSMENT_VALUE = 11;
/**
*
*
*
* This represents an SBOM Reference.
*
*
* SBOM_REFERENCE = 12;
*/
public static final int SBOM_REFERENCE_VALUE = 12;
public final int getNumber() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalArgumentException(
"Can't get the number of an unknown enum value.");
}
return value;
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static NoteKind valueOf(int value) {
return forNumber(value);
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
*/
public static NoteKind forNumber(int value) {
switch (value) {
case 0:
return NOTE_KIND_UNSPECIFIED;
case 1:
return VULNERABILITY;
case 2:
return BUILD;
case 3:
return IMAGE;
case 4:
return PACKAGE;
case 5:
return DEPLOYMENT;
case 6:
return DISCOVERY;
case 7:
return ATTESTATION;
case 8:
return UPGRADE;
case 9:
return COMPLIANCE;
case 10:
return DSSE_ATTESTATION;
case 11:
return VULNERABILITY_ASSESSMENT;
case 12:
return SBOM_REFERENCE;
default:
return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() {
return internalValueMap;
}
private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap =
new com.google.protobuf.Internal.EnumLiteMap() {
public NoteKind findValueByNumber(int number) {
return NoteKind.forNumber(number);
}
};
public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalStateException(
"Can't get the descriptor of an unrecognized enum value.");
}
return getDescriptor().getValues().get(ordinal());
}
public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() {
return getDescriptor();
}
public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() {
return io.grafeas.v1.Common.getDescriptor().getEnumTypes().get(0);
}
private static final NoteKind[] VALUES = values();
public static NoteKind valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
if (desc.getType() != getDescriptor()) {
throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type.");
}
if (desc.getIndex() == -1) {
return UNRECOGNIZED;
}
return VALUES[desc.getIndex()];
}
private final int value;
private NoteKind(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:grafeas.v1.NoteKind)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy