public class NoneAuth extends Auth2
Modifier and Type | Class and Description |
---|---|
static class |
NoneAuth.NoneAuthDescriptor |
Auth2.Auth2Descriptor
Modifier and Type | Field and Description |
---|---|
static Auth2.Auth2Descriptor |
DESCRIPTOR |
static NoneAuth |
INSTANCE |
Constructor and Description |
---|
NoneAuth() |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
Auth2.Auth2Descriptor |
getDescriptor() |
int |
hashCode() |
void |
setAuthorizationHeader(URLConnection connection,
BuildContext context)
Depending on the purpose the Auth2 implementation has to override the
Authorization header of the connection appropriately. |
String |
toString() |
String |
toString(Item item)
Returns a string representing the authorization.
|
@Extension public static final Auth2.Auth2Descriptor DESCRIPTOR
public static final NoneAuth INSTANCE
public void setAuthorizationHeader(URLConnection connection, BuildContext context) throws IOException
Auth2
Authorization
header of the connection appropriately. It might also ignore this
step or remove an existing Authorization
header.setAuthorizationHeader
in class Auth2
connection
- connection between the application and the remote server.context
- the context of this Builder/BuildStep.IOException
- if there is an error generating the authorization header.public String toString(Item item)
Auth2
toString
in class Auth2
item
- the Item (Job, Pipeline,...) we are currently running in.
The item is required to also get Credentials which are defined in the items scope and not Jenkins globally.
Value can be null, but Credentials e.g. configured on a Folder will not be found in this case,
only globally configured Credentials.public Auth2.Auth2Descriptor getDescriptor()
getDescriptor
in interface Describable<Auth2>
getDescriptor
in class AbstractDescribableImpl<Auth2>
Copyright © 2016–2023. All rights reserved.