Class EndpointSlice
- java.lang.Object
-
- com.marcnuri.yakc.model.io.k8s.api.discovery.v1.EndpointSlice
-
- All Implemented Interfaces:
com.marcnuri.yakc.model.Model
public class EndpointSlice extends java.lang.Object implements com.marcnuri.yakc.model.Model
EndpointSlice represents a subset of the endpoints that implement a service. For a given service there may be multiple EndpointSlice objects, selected by labels, which must be joined to produce the full set of endpoints.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
EndpointSlice.Builder
-
Constructor Summary
Constructors Constructor Description EndpointSlice()
EndpointSlice(@NonNull java.lang.String addressType, java.lang.String apiVersion, @NonNull java.util.List<Endpoint> endpoints, java.lang.String kind, ObjectMeta metadata, java.util.List<EndpointPort> ports)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static EndpointSlice.Builder
builder()
protected boolean
canEqual(java.lang.Object other)
boolean
equals(java.lang.Object o)
@NonNull java.lang.String
getAddressType()
addressType specifies the type of address carried by this EndpointSlice.java.lang.String
getApiVersion()
APIVersion defines the versioned schema of this representation of an object.@NonNull java.util.List<Endpoint>
getEndpoints()
endpoints is a list of unique endpoints in this slice.java.lang.String
getKind()
Kind is a string value representing the REST resource this object represents.ObjectMeta
getMetadata()
java.util.List<EndpointPort>
getPorts()
ports specifies the list of network ports exposed by each endpoint in this slice.int
hashCode()
void
setAddressType(@NonNull java.lang.String addressType)
addressType specifies the type of address carried by this EndpointSlice.void
setApiVersion(java.lang.String apiVersion)
APIVersion defines the versioned schema of this representation of an object.void
setEndpoints(@NonNull java.util.List<Endpoint> endpoints)
endpoints is a list of unique endpoints in this slice.void
setKind(java.lang.String kind)
Kind is a string value representing the REST resource this object represents.void
setMetadata(ObjectMeta metadata)
void
setPorts(java.util.List<EndpointPort> ports)
ports specifies the list of network ports exposed by each endpoint in this slice.EndpointSlice.Builder
toBuilder()
java.lang.String
toString()
-
-
-
Constructor Detail
-
EndpointSlice
public EndpointSlice(@NonNull @NonNull java.lang.String addressType, java.lang.String apiVersion, @NonNull @NonNull java.util.List<Endpoint> endpoints, java.lang.String kind, ObjectMeta metadata, java.util.List<EndpointPort> ports)
-
EndpointSlice
public EndpointSlice()
-
-
Method Detail
-
builder
public static EndpointSlice.Builder builder()
-
toBuilder
public EndpointSlice.Builder toBuilder()
-
getAddressType
@NonNull public @NonNull java.lang.String getAddressType()
addressType specifies the type of address carried by this EndpointSlice. All addresses in this slice must be the same type. This field is immutable after creation. The following address types are currently supported: * IPv4: Represents an IPv4 Address. * IPv6: Represents an IPv6 Address. * FQDN: Represents a Fully Qualified Domain Name.
-
getApiVersion
public java.lang.String getApiVersion()
APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
-
getEndpoints
@NonNull public @NonNull java.util.List<Endpoint> getEndpoints()
endpoints is a list of unique endpoints in this slice. Each slice may include a maximum of 1000 endpoints.
-
getKind
public java.lang.String getKind()
Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
-
getMetadata
public ObjectMeta getMetadata()
-
getPorts
public java.util.List<EndpointPort> getPorts()
ports specifies the list of network ports exposed by each endpoint in this slice. Each port must have a unique name. When ports is empty, it indicates that there are no defined ports. When a port is defined with a nil port value, it indicates "all ports". Each slice may include a maximum of 100 ports.
-
setAddressType
public void setAddressType(@NonNull @NonNull java.lang.String addressType)
addressType specifies the type of address carried by this EndpointSlice. All addresses in this slice must be the same type. This field is immutable after creation. The following address types are currently supported: * IPv4: Represents an IPv4 Address. * IPv6: Represents an IPv6 Address. * FQDN: Represents a Fully Qualified Domain Name.
-
setApiVersion
public void setApiVersion(java.lang.String apiVersion)
APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
-
setEndpoints
public void setEndpoints(@NonNull @NonNull java.util.List<Endpoint> endpoints)
endpoints is a list of unique endpoints in this slice. Each slice may include a maximum of 1000 endpoints.
-
setKind
public void setKind(java.lang.String kind)
Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
-
setMetadata
public void setMetadata(ObjectMeta metadata)
-
setPorts
public void setPorts(java.util.List<EndpointPort> ports)
ports specifies the list of network ports exposed by each endpoint in this slice. Each port must have a unique name. When ports is empty, it indicates that there are no defined ports. When a port is defined with a nil port value, it indicates "all ports". Each slice may include a maximum of 100 ports.
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
canEqual
protected boolean canEqual(java.lang.Object other)
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-