id int32 0 165k | repo stringlengths 7 58 | path stringlengths 12 218 | func_name stringlengths 3 140 | original_string stringlengths 73 34.1k | language stringclasses 1
value | code stringlengths 73 34.1k | code_tokens list | docstring stringlengths 3 16k | docstring_tokens list | sha stringlengths 40 40 | url stringlengths 105 339 |
|---|---|---|---|---|---|---|---|---|---|---|---|
15,700 | knowm/XChange | xchange-dragonex/src/main/java/org/knowm/xchange/dragonex/service/DragonexBaseService.java | DragonexBaseService.utcNow | protected static String utcNow() {
Calendar calendar = Calendar.getInstance();
SimpleDateFormat dateFormat = new SimpleDateFormat("EEE, dd MMM yyyy HH:mm:ss z", Locale.US);
dateFormat.setTimeZone(TimeZone.getTimeZone("GMT"));
return dateFormat.format(calendar.getTime());
// return java.time.format.... | java | protected static String utcNow() {
Calendar calendar = Calendar.getInstance();
SimpleDateFormat dateFormat = new SimpleDateFormat("EEE, dd MMM yyyy HH:mm:ss z", Locale.US);
dateFormat.setTimeZone(TimeZone.getTimeZone("GMT"));
return dateFormat.format(calendar.getTime());
// return java.time.format.... | [
"protected",
"static",
"String",
"utcNow",
"(",
")",
"{",
"Calendar",
"calendar",
"=",
"Calendar",
".",
"getInstance",
"(",
")",
";",
"SimpleDateFormat",
"dateFormat",
"=",
"new",
"SimpleDateFormat",
"(",
"\"EEE, dd MMM yyyy HH:mm:ss z\"",
",",
"Locale",
".",
"US"... | current date in utc as http header | [
"current",
"date",
"in",
"utc",
"as",
"http",
"header"
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-dragonex/src/main/java/org/knowm/xchange/dragonex/service/DragonexBaseService.java#L21-L29 |
15,701 | knowm/XChange | xchange-huobi/src/main/java/org/knowm/xchange/huobi/HuobiAdapters.java | HuobiAdapters.adaptTicker | public static Ticker adaptTicker(HuobiTicker huobiTicker, CurrencyPair currencyPair) {
Ticker.Builder builder = new Ticker.Builder();
builder.open(huobiTicker.getOpen());
builder.ask(huobiTicker.getAsk().getPrice());
builder.bid(huobiTicker.getBid().getPrice());
builder.last(huobiTicker.getClose());... | java | public static Ticker adaptTicker(HuobiTicker huobiTicker, CurrencyPair currencyPair) {
Ticker.Builder builder = new Ticker.Builder();
builder.open(huobiTicker.getOpen());
builder.ask(huobiTicker.getAsk().getPrice());
builder.bid(huobiTicker.getBid().getPrice());
builder.last(huobiTicker.getClose());... | [
"public",
"static",
"Ticker",
"adaptTicker",
"(",
"HuobiTicker",
"huobiTicker",
",",
"CurrencyPair",
"currencyPair",
")",
"{",
"Ticker",
".",
"Builder",
"builder",
"=",
"new",
"Ticker",
".",
"Builder",
"(",
")",
";",
"builder",
".",
"open",
"(",
"huobiTicker",... | Trading fee at Huobi is 0.2 % | [
"Trading",
"fee",
"at",
"Huobi",
"is",
"0",
".",
"2",
"%"
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-huobi/src/main/java/org/knowm/xchange/huobi/HuobiAdapters.java#L42-L54 |
15,702 | knowm/XChange | xchange-therock/src/main/java/org/knowm/xchange/therock/service/TheRockAccountServiceRaw.java | TheRockAccountServiceRaw.withdrawDefault | public TheRockWithdrawalResponse withdrawDefault(
Currency currency, BigDecimal amount, String destinationAddress)
throws TheRockException, IOException {
final TheRockWithdrawal withdrawal =
TheRockWithdrawal.createDefaultWithdrawal(
currency.getCurrencyCode(), amount, destinationAdd... | java | public TheRockWithdrawalResponse withdrawDefault(
Currency currency, BigDecimal amount, String destinationAddress)
throws TheRockException, IOException {
final TheRockWithdrawal withdrawal =
TheRockWithdrawal.createDefaultWithdrawal(
currency.getCurrencyCode(), amount, destinationAdd... | [
"public",
"TheRockWithdrawalResponse",
"withdrawDefault",
"(",
"Currency",
"currency",
",",
"BigDecimal",
"amount",
",",
"String",
"destinationAddress",
")",
"throws",
"TheRockException",
",",
"IOException",
"{",
"final",
"TheRockWithdrawal",
"withdrawal",
"=",
"TheRockWi... | Withdraw using the default method | [
"Withdraw",
"using",
"the",
"default",
"method"
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-therock/src/main/java/org/knowm/xchange/therock/service/TheRockAccountServiceRaw.java#L37-L45 |
15,703 | knowm/XChange | xchange-therock/src/main/java/org/knowm/xchange/therock/service/TheRockAccountServiceRaw.java | TheRockAccountServiceRaw.withdrawRipple | public TheRockWithdrawalResponse withdrawRipple(
Currency currency, BigDecimal amount, String destinationAddress, Long destinationTag)
throws TheRockException, IOException {
final TheRockWithdrawal withdrawal =
TheRockWithdrawal.createRippleWithdrawal(
currency.getCurrencyCode(), amo... | java | public TheRockWithdrawalResponse withdrawRipple(
Currency currency, BigDecimal amount, String destinationAddress, Long destinationTag)
throws TheRockException, IOException {
final TheRockWithdrawal withdrawal =
TheRockWithdrawal.createRippleWithdrawal(
currency.getCurrencyCode(), amo... | [
"public",
"TheRockWithdrawalResponse",
"withdrawRipple",
"(",
"Currency",
"currency",
",",
"BigDecimal",
"amount",
",",
"String",
"destinationAddress",
",",
"Long",
"destinationTag",
")",
"throws",
"TheRockException",
",",
"IOException",
"{",
"final",
"TheRockWithdrawal",... | Withdraw to Ripple | [
"Withdraw",
"to",
"Ripple"
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-therock/src/main/java/org/knowm/xchange/therock/service/TheRockAccountServiceRaw.java#L48-L56 |
15,704 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/v2/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.getCoinbaseAccounts | public List<CoinbaseAccount> getCoinbaseAccounts() throws IOException {
String apiKey = exchange.getExchangeSpecification().getApiKey();
BigDecimal timestamp = coinbase.getTime(Coinbase.CB_VERSION_VALUE).getData().getEpoch();
return coinbase
.getAccounts(Coinbase.CB_VERSION_VALUE, apiKey, signature... | java | public List<CoinbaseAccount> getCoinbaseAccounts() throws IOException {
String apiKey = exchange.getExchangeSpecification().getApiKey();
BigDecimal timestamp = coinbase.getTime(Coinbase.CB_VERSION_VALUE).getData().getEpoch();
return coinbase
.getAccounts(Coinbase.CB_VERSION_VALUE, apiKey, signature... | [
"public",
"List",
"<",
"CoinbaseAccount",
">",
"getCoinbaseAccounts",
"(",
")",
"throws",
"IOException",
"{",
"String",
"apiKey",
"=",
"exchange",
".",
"getExchangeSpecification",
"(",
")",
".",
"getApiKey",
"(",
")",
";",
"BigDecimal",
"timestamp",
"=",
"coinba... | Authenticated resource that shows the current user accounts.
@see <a
href="https://developers.coinbase.com/api/v2#list-accounts">developers.coinbase.com/api/v2#list-accounts</a> | [
"Authenticated",
"resource",
"that",
"shows",
"the",
"current",
"user",
"accounts",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/v2/service/CoinbaseAccountServiceRaw.java#L52-L59 |
15,705 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/v2/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.getCoinbaseAccount | public CoinbaseAccount getCoinbaseAccount(Currency currency) throws IOException {
String apiKey = exchange.getExchangeSpecification().getApiKey();
BigDecimal timestamp = coinbase.getTime(Coinbase.CB_VERSION_VALUE).getData().getEpoch();
return coinbase
.getAccount(
Coinbase.CB_VERSION_VA... | java | public CoinbaseAccount getCoinbaseAccount(Currency currency) throws IOException {
String apiKey = exchange.getExchangeSpecification().getApiKey();
BigDecimal timestamp = coinbase.getTime(Coinbase.CB_VERSION_VALUE).getData().getEpoch();
return coinbase
.getAccount(
Coinbase.CB_VERSION_VA... | [
"public",
"CoinbaseAccount",
"getCoinbaseAccount",
"(",
"Currency",
"currency",
")",
"throws",
"IOException",
"{",
"String",
"apiKey",
"=",
"exchange",
".",
"getExchangeSpecification",
"(",
")",
".",
"getApiKey",
"(",
")",
";",
"BigDecimal",
"timestamp",
"=",
"coi... | Authenticated resource that shows the current user account for the give currency.
@see <a
href="https://developers.coinbase.com/api/v2#show-an-account">developers.coinbase.com/api/v2#show-an-account</a> | [
"Authenticated",
"resource",
"that",
"shows",
"the",
"current",
"user",
"account",
"for",
"the",
"give",
"currency",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/v2/service/CoinbaseAccountServiceRaw.java#L67-L79 |
15,706 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/v2/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.createCoinbaseAccount | public CoinbaseAccount createCoinbaseAccount(String name) throws IOException {
CreateCoinbaseAccountPayload payload = new CreateCoinbaseAccountPayload(name);
String path = "/v2/accounts";
String apiKey = exchange.getExchangeSpecification().getApiKey();
BigDecimal timestamp = coinbase.getTime(Coinbase.... | java | public CoinbaseAccount createCoinbaseAccount(String name) throws IOException {
CreateCoinbaseAccountPayload payload = new CreateCoinbaseAccountPayload(name);
String path = "/v2/accounts";
String apiKey = exchange.getExchangeSpecification().getApiKey();
BigDecimal timestamp = coinbase.getTime(Coinbase.... | [
"public",
"CoinbaseAccount",
"createCoinbaseAccount",
"(",
"String",
"name",
")",
"throws",
"IOException",
"{",
"CreateCoinbaseAccountPayload",
"payload",
"=",
"new",
"CreateCoinbaseAccountPayload",
"(",
"name",
")",
";",
"String",
"path",
"=",
"\"/v2/accounts\"",
";",
... | Authenticated resource that creates a new BTC account for the current user.
@see <a
href="https://developers.coinbase.com/api/v2#create-account">developers.coinbase.com/api/v2#create-account</a> | [
"Authenticated",
"resource",
"that",
"creates",
"a",
"new",
"BTC",
"account",
"for",
"the",
"current",
"user",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/v2/service/CoinbaseAccountServiceRaw.java#L87-L107 |
15,707 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/v2/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.getCoinbasePaymentMethods | public List<CoinbasePaymentMethod> getCoinbasePaymentMethods() throws IOException {
String apiKey = exchange.getExchangeSpecification().getApiKey();
BigDecimal timestamp = coinbase.getTime(Coinbase.CB_VERSION_VALUE).getData().getEpoch();
return coinbase
.getPaymentMethods(Coinbase.CB_VERSION_VALUE,... | java | public List<CoinbasePaymentMethod> getCoinbasePaymentMethods() throws IOException {
String apiKey = exchange.getExchangeSpecification().getApiKey();
BigDecimal timestamp = coinbase.getTime(Coinbase.CB_VERSION_VALUE).getData().getEpoch();
return coinbase
.getPaymentMethods(Coinbase.CB_VERSION_VALUE,... | [
"public",
"List",
"<",
"CoinbasePaymentMethod",
">",
"getCoinbasePaymentMethods",
"(",
")",
"throws",
"IOException",
"{",
"String",
"apiKey",
"=",
"exchange",
".",
"getExchangeSpecification",
"(",
")",
".",
"getApiKey",
"(",
")",
";",
"BigDecimal",
"timestamp",
"=... | Authenticated resource that shows the current user payment methods.
@see <a
href="https://developers.coinbase.com/api/v2#list-payment-methods">developers.coinbase.com/api/v2?shell#list-payment-methods</a> | [
"Authenticated",
"resource",
"that",
"shows",
"the",
"current",
"user",
"payment",
"methods",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/v2/service/CoinbaseAccountServiceRaw.java#L115-L122 |
15,708 | knowm/XChange | xchange-bitbay/src/main/java/org/knowm/xchange/bitbay/BitbayAdapters.java | BitbayAdapters.adaptTicker | public static Ticker adaptTicker(BitbayTicker bitbayTicker, CurrencyPair currencyPair) {
BigDecimal ask = bitbayTicker.getAsk();
BigDecimal bid = bitbayTicker.getBid();
BigDecimal high = bitbayTicker.getMax();
BigDecimal low = bitbayTicker.getMin();
BigDecimal volume = bitbayTicker.getVolume();
... | java | public static Ticker adaptTicker(BitbayTicker bitbayTicker, CurrencyPair currencyPair) {
BigDecimal ask = bitbayTicker.getAsk();
BigDecimal bid = bitbayTicker.getBid();
BigDecimal high = bitbayTicker.getMax();
BigDecimal low = bitbayTicker.getMin();
BigDecimal volume = bitbayTicker.getVolume();
... | [
"public",
"static",
"Ticker",
"adaptTicker",
"(",
"BitbayTicker",
"bitbayTicker",
",",
"CurrencyPair",
"currencyPair",
")",
"{",
"BigDecimal",
"ask",
"=",
"bitbayTicker",
".",
"getAsk",
"(",
")",
";",
"BigDecimal",
"bid",
"=",
"bitbayTicker",
".",
"getBid",
"(",... | Adapts a BitbayTicker to a Ticker Object
@param bitbayTicker The exchange specific ticker
@param currencyPair (e.g. BTC/USD)
@return The ticker | [
"Adapts",
"a",
"BitbayTicker",
"to",
"a",
"Ticker",
"Object"
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-bitbay/src/main/java/org/knowm/xchange/bitbay/BitbayAdapters.java#L45-L63 |
15,709 | knowm/XChange | xchange-coingi/src/main/java/org/knowm/xchange/coingi/service/CoingiDefaultIdentityProvider.java | CoingiDefaultIdentityProvider.getSignature | public synchronized String getSignature(long nonce) {
return HexEncoder.encode(sha256HMAC.doFinal(buildSignatureData(nonce)))
.toLowerCase(Locale.ROOT);
} | java | public synchronized String getSignature(long nonce) {
return HexEncoder.encode(sha256HMAC.doFinal(buildSignatureData(nonce)))
.toLowerCase(Locale.ROOT);
} | [
"public",
"synchronized",
"String",
"getSignature",
"(",
"long",
"nonce",
")",
"{",
"return",
"HexEncoder",
".",
"encode",
"(",
"sha256HMAC",
".",
"doFinal",
"(",
"buildSignatureData",
"(",
"nonce",
")",
")",
")",
".",
"toLowerCase",
"(",
"Locale",
".",
"ROO... | Returns a valid signature for the given nonce.
@param nonce Request nonce
@return Request signature | [
"Returns",
"a",
"valid",
"signature",
"for",
"the",
"given",
"nonce",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coingi/src/main/java/org/knowm/xchange/coingi/service/CoingiDefaultIdentityProvider.java#L64-L67 |
15,710 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.getCoinbaseUsers | public CoinbaseUsers getCoinbaseUsers() throws IOException {
final CoinbaseUsers users =
coinbase.getUsers(
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFactory());
return users;
} | java | public CoinbaseUsers getCoinbaseUsers() throws IOException {
final CoinbaseUsers users =
coinbase.getUsers(
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFactory());
return users;
} | [
"public",
"CoinbaseUsers",
"getCoinbaseUsers",
"(",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseUsers",
"users",
"=",
"coinbase",
".",
"getUsers",
"(",
"exchange",
".",
"getExchangeSpecification",
"(",
")",
".",
"getApiKey",
"(",
")",
",",
"signatureCreat... | Authenticated resource that shows the current user and their settings.
@return A {@code CoinbaseUsers} wrapper around the current {@code CoinbaseUser} containing
account settings.
@throws IOException
@see <a
href="https://coinbase.com/api/doc/1.0/users/index.html">coinbase.com/api/doc/1.0/users/index.html</a> | [
"Authenticated",
"resource",
"that",
"shows",
"the",
"current",
"user",
"and",
"their",
"settings",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L48-L56 |
15,711 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.redeemCoinbaseToken | public boolean redeemCoinbaseToken(String tokenId) throws IOException {
final CoinbaseBaseResponse response =
coinbase.redeemToken(
tokenId,
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFactory());
return handleRespo... | java | public boolean redeemCoinbaseToken(String tokenId) throws IOException {
final CoinbaseBaseResponse response =
coinbase.redeemToken(
tokenId,
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFactory());
return handleRespo... | [
"public",
"boolean",
"redeemCoinbaseToken",
"(",
"String",
"tokenId",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseBaseResponse",
"response",
"=",
"coinbase",
".",
"redeemToken",
"(",
"tokenId",
",",
"exchange",
".",
"getExchangeSpecification",
"(",
")",
"."... | Authenticated resource which claims a redeemable token for its address and Bitcoin.
@param tokenId
@return True if the redemption was successful.
@throws IOException
@see <a
href="https://coinbase.com/api/doc/1.0/tokens/redeem.html">coinbase.com/api/doc/1.0/tokens/redeem.html</a> | [
"Authenticated",
"resource",
"which",
"claims",
"a",
"redeemable",
"token",
"for",
"its",
"address",
"and",
"Bitcoin",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L89-L98 |
15,712 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.getCoinbaseAddresses | public CoinbaseAddresses getCoinbaseAddresses(
Integer page, final Integer limit, final String filter) throws IOException {
final CoinbaseAddresses receiveResult =
coinbase.getAddresses(
page,
limit,
filter,
exchange.getExchangeSpecification().getApiKey... | java | public CoinbaseAddresses getCoinbaseAddresses(
Integer page, final Integer limit, final String filter) throws IOException {
final CoinbaseAddresses receiveResult =
coinbase.getAddresses(
page,
limit,
filter,
exchange.getExchangeSpecification().getApiKey... | [
"public",
"CoinbaseAddresses",
"getCoinbaseAddresses",
"(",
"Integer",
"page",
",",
"final",
"Integer",
"limit",
",",
"final",
"String",
"filter",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseAddresses",
"receiveResult",
"=",
"coinbase",
".",
"getAddresses",
... | Authenticated resource that returns Bitcoin addresses a user has associated with their account.
@param page Optional parameter to request a desired page of results. Will return page 1 if the
supplied page is null or less than 1.
@param limit Optional parameter to limit the maximum number of results to return. Will ret... | [
"Authenticated",
"resource",
"that",
"returns",
"Bitcoin",
"addresses",
"a",
"user",
"has",
"associated",
"with",
"their",
"account",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L168-L180 |
15,713 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.generateCoinbaseReceiveAddress | public CoinbaseAddress generateCoinbaseReceiveAddress(String callbackUrl, final String label)
throws IOException {
final CoinbaseAddressCallback callbackUrlParam =
new CoinbaseAddressCallback(callbackUrl, label);
final CoinbaseAddress generateReceiveAddress =
coinbase.generateReceiveAddre... | java | public CoinbaseAddress generateCoinbaseReceiveAddress(String callbackUrl, final String label)
throws IOException {
final CoinbaseAddressCallback callbackUrlParam =
new CoinbaseAddressCallback(callbackUrl, label);
final CoinbaseAddress generateReceiveAddress =
coinbase.generateReceiveAddre... | [
"public",
"CoinbaseAddress",
"generateCoinbaseReceiveAddress",
"(",
"String",
"callbackUrl",
",",
"final",
"String",
"label",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseAddressCallback",
"callbackUrlParam",
"=",
"new",
"CoinbaseAddressCallback",
"(",
"callbackUrl"... | Authenticated resource that generates a new Bitcoin receive address for the user.
@param callbackUrl Optional Callback URL to receive instant payment notifications whenever
funds arrive to this address.
@param label Optional text label for the address which can be used to filter against when
calling {@link #getCoinbas... | [
"Authenticated",
"resource",
"that",
"generates",
"a",
"new",
"Bitcoin",
"receive",
"address",
"for",
"the",
"user",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L209-L222 |
15,714 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.getCoinbaseContacts | public CoinbaseContacts getCoinbaseContacts(
Integer page, final Integer limit, final String filter) throws IOException {
final CoinbaseContacts contacts =
coinbase.getContacts(
page,
limit,
filter,
exchange.getExchangeSpecification().getApiKey(),
... | java | public CoinbaseContacts getCoinbaseContacts(
Integer page, final Integer limit, final String filter) throws IOException {
final CoinbaseContacts contacts =
coinbase.getContacts(
page,
limit,
filter,
exchange.getExchangeSpecification().getApiKey(),
... | [
"public",
"CoinbaseContacts",
"getCoinbaseContacts",
"(",
"Integer",
"page",
",",
"final",
"Integer",
"limit",
",",
"final",
"String",
"filter",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseContacts",
"contacts",
"=",
"coinbase",
".",
"getContacts",
"(",
"... | Authenticated resource that returns contacts the user has previously sent to or received from.
@param page Optional parameter to request a desired page of results. Will return page 1 if the
supplied page is null or less than 1.
@param limit Optional parameter to limit the maximum number of results to return. Will retu... | [
"Authenticated",
"resource",
"that",
"returns",
"contacts",
"the",
"user",
"has",
"previously",
"sent",
"to",
"or",
"received",
"from",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L292-L304 |
15,715 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.getCoinbaseTransaction | public CoinbaseTransaction getCoinbaseTransaction(String transactionIdOrIdemField)
throws IOException {
final CoinbaseTransaction transaction =
coinbase.getTransactionDetails(
transactionIdOrIdemField,
exchange.getExchangeSpecification().getApiKey(),
signatureCreat... | java | public CoinbaseTransaction getCoinbaseTransaction(String transactionIdOrIdemField)
throws IOException {
final CoinbaseTransaction transaction =
coinbase.getTransactionDetails(
transactionIdOrIdemField,
exchange.getExchangeSpecification().getApiKey(),
signatureCreat... | [
"public",
"CoinbaseTransaction",
"getCoinbaseTransaction",
"(",
"String",
"transactionIdOrIdemField",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseTransaction",
"transaction",
"=",
"coinbase",
".",
"getTransactionDetails",
"(",
"transactionIdOrIdemField",
",",
"exchan... | Authenticated resource which returns the details of an individual transaction.
@param transactionIdOrIdemField
@return
@throws IOException
@see <a
href="https://coinbase.com/api/doc/1.0/transactions/show.html">coinbase.com/api/doc/1.0/transactions/show.html</a> | [
"Authenticated",
"resource",
"which",
"returns",
"the",
"details",
"of",
"an",
"individual",
"transaction",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L351-L361 |
15,716 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.requestMoneyCoinbaseRequest | public CoinbaseTransaction requestMoneyCoinbaseRequest(
CoinbaseRequestMoneyRequest transactionRequest) throws IOException {
final CoinbaseTransaction pendingTransaction =
coinbase.requestMoney(
new CoinbaseTransaction(transactionRequest),
exchange.getExchangeSpecification().g... | java | public CoinbaseTransaction requestMoneyCoinbaseRequest(
CoinbaseRequestMoneyRequest transactionRequest) throws IOException {
final CoinbaseTransaction pendingTransaction =
coinbase.requestMoney(
new CoinbaseTransaction(transactionRequest),
exchange.getExchangeSpecification().g... | [
"public",
"CoinbaseTransaction",
"requestMoneyCoinbaseRequest",
"(",
"CoinbaseRequestMoneyRequest",
"transactionRequest",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseTransaction",
"pendingTransaction",
"=",
"coinbase",
".",
"requestMoney",
"(",
"new",
"CoinbaseTransact... | Authenticated resource which lets the user request money from a Bitcoin address.
@param transactionRequest
@return A pending {@code CoinbaseTransaction} representing the desired {@code
CoinbaseRequestMoneyRequest}.
@throws IOException
@see <a
href="https://coinbase.com/api/doc/1.0/transactions/request_money.html">coin... | [
"Authenticated",
"resource",
"which",
"lets",
"the",
"user",
"request",
"money",
"from",
"a",
"Bitcoin",
"address",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L373-L383 |
15,717 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.sendMoneyCoinbaseRequest | public CoinbaseTransaction sendMoneyCoinbaseRequest(CoinbaseSendMoneyRequest transactionRequest)
throws IOException {
final CoinbaseTransaction pendingTransaction =
coinbase.sendMoney(
new CoinbaseTransaction(transactionRequest),
exchange.getExchangeSpecification().getApiKey()... | java | public CoinbaseTransaction sendMoneyCoinbaseRequest(CoinbaseSendMoneyRequest transactionRequest)
throws IOException {
final CoinbaseTransaction pendingTransaction =
coinbase.sendMoney(
new CoinbaseTransaction(transactionRequest),
exchange.getExchangeSpecification().getApiKey()... | [
"public",
"CoinbaseTransaction",
"sendMoneyCoinbaseRequest",
"(",
"CoinbaseSendMoneyRequest",
"transactionRequest",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseTransaction",
"pendingTransaction",
"=",
"coinbase",
".",
"sendMoney",
"(",
"new",
"CoinbaseTransaction",
"... | Authenticated resource which lets you send money to an email or Bitcoin address.
@param transactionRequest
@return A completed {@code CoinbaseTransaction} representing the desired {@code
CoinbaseSendMoneyRequest}.
@throws IOException
@see <a
href="https://coinbase.com/api/doc/1.0/transactions/send_money.html">coinbase... | [
"Authenticated",
"resource",
"which",
"lets",
"you",
"send",
"money",
"to",
"an",
"email",
"or",
"Bitcoin",
"address",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L395-L405 |
15,718 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.resendCoinbaseRequest | public CoinbaseBaseResponse resendCoinbaseRequest(String transactionId) throws IOException {
final CoinbaseBaseResponse response =
coinbase.resendRequest(
transactionId,
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFacto... | java | public CoinbaseBaseResponse resendCoinbaseRequest(String transactionId) throws IOException {
final CoinbaseBaseResponse response =
coinbase.resendRequest(
transactionId,
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFacto... | [
"public",
"CoinbaseBaseResponse",
"resendCoinbaseRequest",
"(",
"String",
"transactionId",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseBaseResponse",
"response",
"=",
"coinbase",
".",
"resendRequest",
"(",
"transactionId",
",",
"exchange",
".",
"getExchangeSpecif... | Authenticated resource which lets the user resend a money request.
@param transactionId
@return true if resending the request was successful.
@throws IOException
@see <a
href="https://coinbase.com/api/doc/1.0/transactions/resend_request.html">coinbase.com/api/doc/1.0/transactions/resend_request.html</a> | [
"Authenticated",
"resource",
"which",
"lets",
"the",
"user",
"resend",
"a",
"money",
"request",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L416-L425 |
15,719 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.cancelCoinbaseRequest | public CoinbaseBaseResponse cancelCoinbaseRequest(String transactionId) throws IOException {
final CoinbaseBaseResponse response =
coinbase.cancelRequest(
transactionId,
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFacto... | java | public CoinbaseBaseResponse cancelCoinbaseRequest(String transactionId) throws IOException {
final CoinbaseBaseResponse response =
coinbase.cancelRequest(
transactionId,
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFacto... | [
"public",
"CoinbaseBaseResponse",
"cancelCoinbaseRequest",
"(",
"String",
"transactionId",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseBaseResponse",
"response",
"=",
"coinbase",
".",
"cancelRequest",
"(",
"transactionId",
",",
"exchange",
".",
"getExchangeSpecif... | Authenticated resource which lets a user cancel a money request. Money requests can be canceled
by the sender or the recipient.
@param transactionId
@return true if canceling the request was successful.
@throws IOException
@see <a
href="https://coinbase.com/api/doc/1.0/transactions/cancel_request.html">coinbase.com/ap... | [
"Authenticated",
"resource",
"which",
"lets",
"a",
"user",
"cancel",
"a",
"money",
"request",
".",
"Money",
"requests",
"can",
"be",
"canceled",
"by",
"the",
"sender",
"or",
"the",
"recipient",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L461-L470 |
15,720 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.createCoinbaseButton | public CoinbaseButton createCoinbaseButton(CoinbaseButton button) throws IOException {
final CoinbaseButton createdButton =
coinbase.createButton(
button,
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFactory());
retu... | java | public CoinbaseButton createCoinbaseButton(CoinbaseButton button) throws IOException {
final CoinbaseButton createdButton =
coinbase.createButton(
button,
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFactory());
retu... | [
"public",
"CoinbaseButton",
"createCoinbaseButton",
"(",
"CoinbaseButton",
"button",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseButton",
"createdButton",
"=",
"coinbase",
".",
"createButton",
"(",
"button",
",",
"exchange",
".",
"getExchangeSpecification",
"("... | Authenticated resource that creates a payment button, page, or iFrame to accept Bitcoin on your
website. This can be used to accept Bitcoin for an individual item or to integrate with your
existing shopping cart solution. For example, you could create a new payment button for each
shopping cart on your website, setting... | [
"Authenticated",
"resource",
"that",
"creates",
"a",
"payment",
"button",
"page",
"or",
"iFrame",
"to",
"accept",
"Bitcoin",
"on",
"your",
"website",
".",
"This",
"can",
"be",
"used",
"to",
"accept",
"Bitcoin",
"for",
"an",
"individual",
"item",
"or",
"to",
... | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L485-L494 |
15,721 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.getCoinbaseOrder | public CoinbaseOrder getCoinbaseOrder(String orderIdOrCustom) throws IOException {
final CoinbaseOrder order =
coinbase.getOrder(
orderIdOrCustom,
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFactory());
return handl... | java | public CoinbaseOrder getCoinbaseOrder(String orderIdOrCustom) throws IOException {
final CoinbaseOrder order =
coinbase.getOrder(
orderIdOrCustom,
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFactory());
return handl... | [
"public",
"CoinbaseOrder",
"getCoinbaseOrder",
"(",
"String",
"orderIdOrCustom",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseOrder",
"order",
"=",
"coinbase",
".",
"getOrder",
"(",
"orderIdOrCustom",
",",
"exchange",
".",
"getExchangeSpecification",
"(",
")",... | Authenticated resource which returns order details for a specific order id or merchant custom.
@param orderIdOrCustom
@return
@throws IOException
@see <a
href="https://coinbase.com/api/doc/1.0/orders/show.html">coinbase.com/api/doc/1.0/orders/show.html</a> | [
"Authenticated",
"resource",
"which",
"returns",
"order",
"details",
"for",
"a",
"specific",
"order",
"id",
"or",
"merchant",
"custom",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L542-L551 |
15,722 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.createCoinbaseOrder | public CoinbaseOrder createCoinbaseOrder(CoinbaseButton button) throws IOException {
final CoinbaseOrder createdOrder =
coinbase.createOrder(
button,
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFactory());
return ha... | java | public CoinbaseOrder createCoinbaseOrder(CoinbaseButton button) throws IOException {
final CoinbaseOrder createdOrder =
coinbase.createOrder(
button,
exchange.getExchangeSpecification().getApiKey(),
signatureCreator,
exchange.getNonceFactory());
return ha... | [
"public",
"CoinbaseOrder",
"createCoinbaseOrder",
"(",
"CoinbaseButton",
"button",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseOrder",
"createdOrder",
"=",
"coinbase",
".",
"createOrder",
"(",
"button",
",",
"exchange",
".",
"getExchangeSpecification",
"(",
"... | Authenticated resource which returns an order for a new button.
@param button A {@code CoinbaseButton} containing information to create a one time order.
@return The newly created {@code CoinbaseOrder}.
@throws IOException
@see <a
href="https://coinbase.com/api/doc/1.0/orders/create.html">coinbase.com/api/doc/1.0/orde... | [
"Authenticated",
"resource",
"which",
"returns",
"an",
"order",
"for",
"a",
"new",
"button",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L584-L593 |
15,723 | knowm/XChange | xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java | CoinbaseAccountServiceRaw.getCoinbaseRecurringPayment | public CoinbaseRecurringPayment getCoinbaseRecurringPayment(String recurringPaymentId)
throws IOException {
final CoinbaseRecurringPayment recurringPayment =
coinbase.getRecurringPayment(
recurringPaymentId,
exchange.getExchangeSpecification().getApiKey(),
signatur... | java | public CoinbaseRecurringPayment getCoinbaseRecurringPayment(String recurringPaymentId)
throws IOException {
final CoinbaseRecurringPayment recurringPayment =
coinbase.getRecurringPayment(
recurringPaymentId,
exchange.getExchangeSpecification().getApiKey(),
signatur... | [
"public",
"CoinbaseRecurringPayment",
"getCoinbaseRecurringPayment",
"(",
"String",
"recurringPaymentId",
")",
"throws",
"IOException",
"{",
"final",
"CoinbaseRecurringPayment",
"recurringPayment",
"=",
"coinbase",
".",
"getRecurringPayment",
"(",
"recurringPaymentId",
",",
"... | Authenticated resource that lets you show an individual recurring payment.
@param recurringPaymentId
@return
@throws IOException
@see <a
href="https://coinbase.com/api/doc/1.0/recurring_payments/show.html">coinbase.com/api/doc/1.0/recurring_payments/show.html</a> | [
"Authenticated",
"resource",
"that",
"lets",
"you",
"show",
"an",
"individual",
"recurring",
"payment",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-coinbase/src/main/java/org/knowm/xchange/coinbase/service/CoinbaseAccountServiceRaw.java#L645-L655 |
15,724 | knowm/XChange | xchange-dsx/src/main/java/org/knowm/xchange/dsx/service/core/DSXTradeServiceCoreRaw.java | DSXTradeServiceCoreRaw.getDSXTradeHistory | public Map<Long, DSXTradeHistoryResult> getDSXTradeHistory(
Integer count,
Long fromId,
Long endId,
DSXAuthenticatedV2.SortOrder order,
Long since,
Long end,
String pair)
throws IOException {
DSXTradeHistoryReturn dsxTradeHistory =
dsx.tradeHistory(
... | java | public Map<Long, DSXTradeHistoryResult> getDSXTradeHistory(
Integer count,
Long fromId,
Long endId,
DSXAuthenticatedV2.SortOrder order,
Long since,
Long end,
String pair)
throws IOException {
DSXTradeHistoryReturn dsxTradeHistory =
dsx.tradeHistory(
... | [
"public",
"Map",
"<",
"Long",
",",
"DSXTradeHistoryResult",
">",
"getDSXTradeHistory",
"(",
"Integer",
"count",
",",
"Long",
"fromId",
",",
"Long",
"endId",
",",
"DSXAuthenticatedV2",
".",
"SortOrder",
"order",
",",
"Long",
"since",
",",
"Long",
"end",
",",
... | Get Map of trade history from DSX exchange. All parameters are nullable
@param count Number of trades to display
@param fromId ID of the first trade of the selection
@param endId ID of the last trade of the selection
@param order Order in which transactions shown. Possible values: «asc» — from first to last,
«desc» — ... | [
"Get",
"Map",
"of",
"trade",
"history",
"from",
"DSX",
"exchange",
".",
"All",
"parameters",
"are",
"nullable"
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-dsx/src/main/java/org/knowm/xchange/dsx/service/core/DSXTradeServiceCoreRaw.java#L142-L171 |
15,725 | knowm/XChange | xchange-dsx/src/main/java/org/knowm/xchange/dsx/service/core/DSXTradeServiceCoreRaw.java | DSXTradeServiceCoreRaw.getDSXTransHistory | public Map<Long, DSXTransHistoryResult> getDSXTransHistory(
Integer count,
Long fromId,
Long endId,
DSXAuthenticatedV2.SortOrder order,
Long since,
Long end,
DSXTransHistoryResult.Type type,
DSXTransHistoryResult.Status status,
String currency)
throws IOExcept... | java | public Map<Long, DSXTransHistoryResult> getDSXTransHistory(
Integer count,
Long fromId,
Long endId,
DSXAuthenticatedV2.SortOrder order,
Long since,
Long end,
DSXTransHistoryResult.Type type,
DSXTransHistoryResult.Status status,
String currency)
throws IOExcept... | [
"public",
"Map",
"<",
"Long",
",",
"DSXTransHistoryResult",
">",
"getDSXTransHistory",
"(",
"Integer",
"count",
",",
"Long",
"fromId",
",",
"Long",
"endId",
",",
"DSXAuthenticatedV2",
".",
"SortOrder",
"order",
",",
"Long",
"since",
",",
"Long",
"end",
",",
... | Get Map of transaction history from DSX exchange. All parameters are nullable
@param count Number of transactions to display. Default value is 1000
@param fromId ID of the first transaction of the selection
@param endId ID of the last transaction of the selection
@param order Order in which transactions shown. Possibl... | [
"Get",
"Map",
"of",
"transaction",
"history",
"from",
"DSX",
"exchange",
".",
"All",
"parameters",
"are",
"nullable"
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-dsx/src/main/java/org/knowm/xchange/dsx/service/core/DSXTradeServiceCoreRaw.java#L188-L221 |
15,726 | knowm/XChange | xchange-dsx/src/main/java/org/knowm/xchange/dsx/service/core/DSXTradeServiceCoreRaw.java | DSXTradeServiceCoreRaw.getDSXOrderHistory | public Map<Long, DSXOrderHistoryResult> getDSXOrderHistory(
Long count,
Long fromId,
Long endId,
DSXAuthenticatedV2.SortOrder order,
Long since,
Long end,
String pair)
throws IOException {
DSXOrderHistoryReturn dsxOrderHistory =
dsx.orderHistory(
... | java | public Map<Long, DSXOrderHistoryResult> getDSXOrderHistory(
Long count,
Long fromId,
Long endId,
DSXAuthenticatedV2.SortOrder order,
Long since,
Long end,
String pair)
throws IOException {
DSXOrderHistoryReturn dsxOrderHistory =
dsx.orderHistory(
... | [
"public",
"Map",
"<",
"Long",
",",
"DSXOrderHistoryResult",
">",
"getDSXOrderHistory",
"(",
"Long",
"count",
",",
"Long",
"fromId",
",",
"Long",
"endId",
",",
"DSXAuthenticatedV2",
".",
"SortOrder",
"order",
",",
"Long",
"since",
",",
"Long",
"end",
",",
"St... | Get Map of order history from DSX exchange. All parameters are nullable
@param count Number of orders to display. Default value is 1000
@param fromId ID of the first order of the selection
@param endId ID of the last order of the selection
@param order Order in which transactions shown. Possible values: «asc» — from f... | [
"Get",
"Map",
"of",
"order",
"history",
"from",
"DSX",
"exchange",
".",
"All",
"parameters",
"are",
"nullable"
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-dsx/src/main/java/org/knowm/xchange/dsx/service/core/DSXTradeServiceCoreRaw.java#L239-L268 |
15,727 | knowm/XChange | xchange-bitfinex/src/main/java/org/knowm/xchange/bitfinex/v1/BitfinexAdapters.java | BitfinexAdapters.adaptDynamicTradingFees | public static Map<CurrencyPair, Fee> adaptDynamicTradingFees(
BitfinexTradingFeeResponse[] responses, List<CurrencyPair> currencyPairs) {
Map<CurrencyPair, Fee> result = new HashMap<>();
for (BitfinexTradingFeeResponse response : responses) {
BitfinexTradingFeeResponse.BitfinexTradingFeeResponseRow[... | java | public static Map<CurrencyPair, Fee> adaptDynamicTradingFees(
BitfinexTradingFeeResponse[] responses, List<CurrencyPair> currencyPairs) {
Map<CurrencyPair, Fee> result = new HashMap<>();
for (BitfinexTradingFeeResponse response : responses) {
BitfinexTradingFeeResponse.BitfinexTradingFeeResponseRow[... | [
"public",
"static",
"Map",
"<",
"CurrencyPair",
",",
"Fee",
">",
"adaptDynamicTradingFees",
"(",
"BitfinexTradingFeeResponse",
"[",
"]",
"responses",
",",
"List",
"<",
"CurrencyPair",
">",
"currencyPairs",
")",
"{",
"Map",
"<",
"CurrencyPair",
",",
"Fee",
">",
... | Each element in the response array contains a set of currencies that are at a given fee tier.
The API returns the fee per currency in each tier and does not make any promises that they are
all the same, so this adapter will use the fee per currency instead of the fee per tier. | [
"Each",
"element",
"in",
"the",
"response",
"array",
"contains",
"a",
"set",
"of",
"currencies",
"that",
"are",
"at",
"a",
"given",
"fee",
"tier",
".",
"The",
"API",
"returns",
"the",
"fee",
"per",
"currency",
"in",
"each",
"tier",
"and",
"does",
"not",
... | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-bitfinex/src/main/java/org/knowm/xchange/bitfinex/v1/BitfinexAdapters.java#L72-L98 |
15,728 | knowm/XChange | xchange-ripple/src/main/java/org/knowm/xchange/ripple/service/RippleTradeServiceRaw.java | RippleTradeServiceRaw.getTrade | public IRippleTradeTransaction getTrade(
final String account, final RippleNotification notification)
throws RippleException, IOException {
final RippleExchange ripple = (RippleExchange) exchange;
if (ripple.isStoreTradeTransactionDetails()) {
Map<String, IRippleTradeTransaction> cache = rawTr... | java | public IRippleTradeTransaction getTrade(
final String account, final RippleNotification notification)
throws RippleException, IOException {
final RippleExchange ripple = (RippleExchange) exchange;
if (ripple.isStoreTradeTransactionDetails()) {
Map<String, IRippleTradeTransaction> cache = rawTr... | [
"public",
"IRippleTradeTransaction",
"getTrade",
"(",
"final",
"String",
"account",
",",
"final",
"RippleNotification",
"notification",
")",
"throws",
"RippleException",
",",
"IOException",
"{",
"final",
"RippleExchange",
"ripple",
"=",
"(",
"RippleExchange",
")",
"ex... | Retrieve order details from local store if they have been previously stored otherwise query
external server. | [
"Retrieve",
"order",
"details",
"from",
"local",
"store",
"if",
"they",
"have",
"been",
"previously",
"stored",
"otherwise",
"query",
"external",
"server",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-ripple/src/main/java/org/knowm/xchange/ripple/service/RippleTradeServiceRaw.java#L175-L224 |
15,729 | knowm/XChange | xchange-ripple/src/main/java/org/knowm/xchange/ripple/service/RippleTradeServiceRaw.java | RippleTradeServiceRaw.clearOrderDetailsStore | public void clearOrderDetailsStore() {
for (final Map<String, IRippleTradeTransaction> cache : rawTradeStore.values()) {
cache.clear();
}
rawTradeStore.clear();
} | java | public void clearOrderDetailsStore() {
for (final Map<String, IRippleTradeTransaction> cache : rawTradeStore.values()) {
cache.clear();
}
rawTradeStore.clear();
} | [
"public",
"void",
"clearOrderDetailsStore",
"(",
")",
"{",
"for",
"(",
"final",
"Map",
"<",
"String",
",",
"IRippleTradeTransaction",
">",
"cache",
":",
"rawTradeStore",
".",
"values",
"(",
")",
")",
"{",
"cache",
".",
"clear",
"(",
")",
";",
"}",
"rawTr... | Clear any stored order details to allow memory to be released. | [
"Clear",
"any",
"stored",
"order",
"details",
"to",
"allow",
"memory",
"to",
"be",
"released",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-ripple/src/main/java/org/knowm/xchange/ripple/service/RippleTradeServiceRaw.java#L406-L411 |
15,730 | knowm/XChange | xchange-core/src/main/java/org/knowm/xchange/utils/retries/Retries.java | Retries.callWithRetries | public static <V> V callWithRetries(
int nAttempts,
int initialRetrySec,
Callable<V> action,
IPredicate<Exception> retryableException)
throws Exception {
int retryDelaySec = initialRetrySec;
for (int attemptsLeftAfterThis = nAttempts - 1;
attemptsLeftAfterThis >= 0;
... | java | public static <V> V callWithRetries(
int nAttempts,
int initialRetrySec,
Callable<V> action,
IPredicate<Exception> retryableException)
throws Exception {
int retryDelaySec = initialRetrySec;
for (int attemptsLeftAfterThis = nAttempts - 1;
attemptsLeftAfterThis >= 0;
... | [
"public",
"static",
"<",
"V",
">",
"V",
"callWithRetries",
"(",
"int",
"nAttempts",
",",
"int",
"initialRetrySec",
",",
"Callable",
"<",
"V",
">",
"action",
",",
"IPredicate",
"<",
"Exception",
">",
"retryableException",
")",
"throws",
"Exception",
"{",
"int... | Allows a client to attempt a call and retry a finite amount of times if the exception thrown is
the right kind. The retries back off exponentially.
@param nAttempts Number of attempts before giving up
@param initialRetrySec Number of seconds to wait before trying again on the first retry.
@param action A callable or l... | [
"Allows",
"a",
"client",
"to",
"attempt",
"a",
"call",
"and",
"retry",
"a",
"finite",
"amount",
"of",
"times",
"if",
"the",
"exception",
"thrown",
"is",
"the",
"right",
"kind",
".",
"The",
"retries",
"back",
"off",
"exponentially",
"."
] | e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186 | https://github.com/knowm/XChange/blob/e45f437ac8e0b89cd66cdcb3258bdb1bf3d88186/xchange-core/src/main/java/org/knowm/xchange/utils/retries/Retries.java#L28-L52 |
15,731 | fabric8io/kubernetes-client | kubernetes-server-mock/src/main/java/io/fabric8/kubernetes/client/server/mock/KubernetesResponseComposer.java | KubernetesResponseComposer.join | private static String join(String sep, Collection<String> collection) {
StringBuilder builder = new StringBuilder();
boolean first = true;
for (String element : collection) {
if (first) {
first = false;
} else {
builder.append(sep);
}
builder.append(element);
}
... | java | private static String join(String sep, Collection<String> collection) {
StringBuilder builder = new StringBuilder();
boolean first = true;
for (String element : collection) {
if (first) {
first = false;
} else {
builder.append(sep);
}
builder.append(element);
}
... | [
"private",
"static",
"String",
"join",
"(",
"String",
"sep",
",",
"Collection",
"<",
"String",
">",
"collection",
")",
"{",
"StringBuilder",
"builder",
"=",
"new",
"StringBuilder",
"(",
")",
";",
"boolean",
"first",
"=",
"true",
";",
"for",
"(",
"String",
... | This is a reimplementation of Java 8's String.join. | [
"This",
"is",
"a",
"reimplementation",
"of",
"Java",
"8",
"s",
"String",
".",
"join",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-server-mock/src/main/java/io/fabric8/kubernetes/client/server/mock/KubernetesResponseComposer.java#L25-L37 |
15,732 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/ApiVersionUtil.java | ApiVersionUtil.apiVersion | public static <T> String apiVersion(T item, String apiVersion) {
if (item instanceof HasMetadata && Utils.isNotNullOrEmpty(((HasMetadata) item).getApiVersion())) {
return trimVersion(((HasMetadata) item).getApiVersion());
} else if (apiVersion != null && !apiVersion.isEmpty()) {
return trimVersion(a... | java | public static <T> String apiVersion(T item, String apiVersion) {
if (item instanceof HasMetadata && Utils.isNotNullOrEmpty(((HasMetadata) item).getApiVersion())) {
return trimVersion(((HasMetadata) item).getApiVersion());
} else if (apiVersion != null && !apiVersion.isEmpty()) {
return trimVersion(a... | [
"public",
"static",
"<",
"T",
">",
"String",
"apiVersion",
"(",
"T",
"item",
",",
"String",
"apiVersion",
")",
"{",
"if",
"(",
"item",
"instanceof",
"HasMetadata",
"&&",
"Utils",
".",
"isNotNullOrEmpty",
"(",
"(",
"(",
"HasMetadata",
")",
"item",
")",
".... | Returns the api version falling back to the items apiGroupVersion if not null.
@param <T> type of parameter
@param item item to be processed
@param apiVersion apiVersion string
@return returns api version | [
"Returns",
"the",
"api",
"version",
"falling",
"back",
"to",
"the",
"items",
"apiGroupVersion",
"if",
"not",
"null",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/ApiVersionUtil.java#L45-L52 |
15,733 | fabric8io/kubernetes-client | openshift-client/src/main/java/io/fabric8/openshift/client/OpenshiftAdapterSupport.java | OpenshiftAdapterSupport.isOpenShift | static boolean isOpenShift(Client client) {
URL masterUrl = client.getMasterUrl();
if (IS_OPENSHIFT.containsKey(masterUrl)) {
return IS_OPENSHIFT.get(masterUrl);
} else {
RootPaths rootPaths = client.rootPaths();
if (rootPaths != null) {
List<S... | java | static boolean isOpenShift(Client client) {
URL masterUrl = client.getMasterUrl();
if (IS_OPENSHIFT.containsKey(masterUrl)) {
return IS_OPENSHIFT.get(masterUrl);
} else {
RootPaths rootPaths = client.rootPaths();
if (rootPaths != null) {
List<S... | [
"static",
"boolean",
"isOpenShift",
"(",
"Client",
"client",
")",
"{",
"URL",
"masterUrl",
"=",
"client",
".",
"getMasterUrl",
"(",
")",
";",
"if",
"(",
"IS_OPENSHIFT",
".",
"containsKey",
"(",
"masterUrl",
")",
")",
"{",
"return",
"IS_OPENSHIFT",
".",
"ge... | Check if OpenShift is available.
@param client The client.
@return True if oapi is found in the root paths. | [
"Check",
"if",
"OpenShift",
"is",
"available",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/openshift-client/src/main/java/io/fabric8/openshift/client/OpenshiftAdapterSupport.java#L48-L76 |
15,734 | fabric8io/kubernetes-client | openshift-client/src/main/java/io/fabric8/openshift/client/OpenshiftAdapterSupport.java | OpenshiftAdapterSupport.isOpenShiftAPIGroups | static boolean isOpenShiftAPIGroups(Client client) {
Config configuration = client.getConfiguration();
if (configuration instanceof OpenShiftConfig) {
OpenShiftConfig openShiftConfig = (OpenShiftConfig) configuration;
if (openShiftConfig.isDisableApiGroupCheck()) {
... | java | static boolean isOpenShiftAPIGroups(Client client) {
Config configuration = client.getConfiguration();
if (configuration instanceof OpenShiftConfig) {
OpenShiftConfig openShiftConfig = (OpenShiftConfig) configuration;
if (openShiftConfig.isDisableApiGroupCheck()) {
... | [
"static",
"boolean",
"isOpenShiftAPIGroups",
"(",
"Client",
"client",
")",
"{",
"Config",
"configuration",
"=",
"client",
".",
"getConfiguration",
"(",
")",
";",
"if",
"(",
"configuration",
"instanceof",
"OpenShiftConfig",
")",
"{",
"OpenShiftConfig",
"openShiftConf... | Check if OpenShift API Groups are available
@param client The client.
@return True if the new <code>/apis/*.openshift.io/</code> APIs are found in the root paths. | [
"Check",
"if",
"OpenShift",
"API",
"Groups",
"are",
"available"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/openshift-client/src/main/java/io/fabric8/openshift/client/OpenshiftAdapterSupport.java#L83-L96 |
15,735 | fabric8io/kubernetes-client | openshift-client/src/main/java/io/fabric8/openshift/client/OpenshiftAdapterSupport.java | OpenshiftAdapterSupport.hasCustomOpenShiftUrl | static boolean hasCustomOpenShiftUrl(OpenShiftConfig config) {
try {
URI masterUri = new URI(config.getMasterUrl()).resolve("/");
URI openshfitUri = new URI(config.getOpenShiftUrl()).resolve("/");
return !masterUri.equals(openshfitUri);
} catch (Exception e) {
... | java | static boolean hasCustomOpenShiftUrl(OpenShiftConfig config) {
try {
URI masterUri = new URI(config.getMasterUrl()).resolve("/");
URI openshfitUri = new URI(config.getOpenShiftUrl()).resolve("/");
return !masterUri.equals(openshfitUri);
} catch (Exception e) {
... | [
"static",
"boolean",
"hasCustomOpenShiftUrl",
"(",
"OpenShiftConfig",
"config",
")",
"{",
"try",
"{",
"URI",
"masterUri",
"=",
"new",
"URI",
"(",
"config",
".",
"getMasterUrl",
"(",
")",
")",
".",
"resolve",
"(",
"\"/\"",
")",
";",
"URI",
"openshfitUri",
"... | Checks if a custom URL for OpenShift has been used.
@param config The openshift configuration.
@return True if both master and openshift url have the same root. | [
"Checks",
"if",
"a",
"custom",
"URL",
"for",
"OpenShift",
"has",
"been",
"used",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/openshift-client/src/main/java/io/fabric8/openshift/client/OpenshiftAdapterSupport.java#L104-L112 |
15,736 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/KubernetesClientTimeoutException.java | KubernetesClientTimeoutException.notReadyToString | private static String notReadyToString(Iterable<HasMetadata> resources) {
StringBuilder sb = new StringBuilder();
sb.append("Resources that are not ready: ");
boolean first = true;
for (HasMetadata r : resources) {
if (first) {
first = false;
} else {
sb.append(", ");
}... | java | private static String notReadyToString(Iterable<HasMetadata> resources) {
StringBuilder sb = new StringBuilder();
sb.append("Resources that are not ready: ");
boolean first = true;
for (HasMetadata r : resources) {
if (first) {
first = false;
} else {
sb.append(", ");
}... | [
"private",
"static",
"String",
"notReadyToString",
"(",
"Iterable",
"<",
"HasMetadata",
">",
"resources",
")",
"{",
"StringBuilder",
"sb",
"=",
"new",
"StringBuilder",
"(",
")",
";",
"sb",
".",
"append",
"(",
"\"Resources that are not ready: \"",
")",
";",
"bool... | Creates a string listing all the resources that are not ready.
@param resources The resources that are not ready.
@return | [
"Creates",
"a",
"string",
"listing",
"all",
"the",
"resources",
"that",
"are",
"not",
"ready",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/KubernetesClientTimeoutException.java#L53-L69 |
15,737 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/Serialization.java | Serialization.unmarshal | public static <T> T unmarshal(InputStream is, ObjectMapper mapper) {
return unmarshal(is, mapper, Collections.<String, String>emptyMap());
} | java | public static <T> T unmarshal(InputStream is, ObjectMapper mapper) {
return unmarshal(is, mapper, Collections.<String, String>emptyMap());
} | [
"public",
"static",
"<",
"T",
">",
"T",
"unmarshal",
"(",
"InputStream",
"is",
",",
"ObjectMapper",
"mapper",
")",
"{",
"return",
"unmarshal",
"(",
"is",
",",
"mapper",
",",
"Collections",
".",
"<",
"String",
",",
"String",
">",
"emptyMap",
"(",
")",
"... | Unmarshals a stream.
@param is The {@link InputStream}.
@param mapper The {@link ObjectMapper} to use.
@param <T> The target type.
@return returns de-serialized object
@throws KubernetesClientException KubernetesClientException | [
"Unmarshals",
"a",
"stream",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/Serialization.java#L106-L108 |
15,738 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/internal/RollableScalableResourceOperation.java | RollableScalableResourceOperation.waitUntilScaled | private void waitUntilScaled(final int count) {
final ArrayBlockingQueue<Object> queue = new ArrayBlockingQueue<>(1);
final AtomicReference<Integer> replicasRef = new AtomicReference<>(0);
final String name = checkName(getItem());
final String namespace = checkNamespace(getItem());
final Runnable ... | java | private void waitUntilScaled(final int count) {
final ArrayBlockingQueue<Object> queue = new ArrayBlockingQueue<>(1);
final AtomicReference<Integer> replicasRef = new AtomicReference<>(0);
final String name = checkName(getItem());
final String namespace = checkNamespace(getItem());
final Runnable ... | [
"private",
"void",
"waitUntilScaled",
"(",
"final",
"int",
"count",
")",
"{",
"final",
"ArrayBlockingQueue",
"<",
"Object",
">",
"queue",
"=",
"new",
"ArrayBlockingQueue",
"<>",
"(",
"1",
")",
";",
"final",
"AtomicReference",
"<",
"Integer",
">",
"replicasRef"... | Let's wait until there are enough Ready pods. | [
"Let",
"s",
"wait",
"until",
"there",
"are",
"enough",
"Ready",
"pods",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/internal/RollableScalableResourceOperation.java#L85-L133 |
15,739 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/internal/RollingUpdater.java | RollingUpdater.waitUntilPodsAreReady | private void waitUntilPodsAreReady(final T obj, final String namespace, final int requiredPodCount) {
final CountDownLatch countDownLatch = new CountDownLatch(1);
final AtomicInteger podCount = new AtomicInteger(0);
final Runnable readyPodsPoller = () -> {
PodList podList = listSelectedPods(obj);
... | java | private void waitUntilPodsAreReady(final T obj, final String namespace, final int requiredPodCount) {
final CountDownLatch countDownLatch = new CountDownLatch(1);
final AtomicInteger podCount = new AtomicInteger(0);
final Runnable readyPodsPoller = () -> {
PodList podList = listSelectedPods(obj);
... | [
"private",
"void",
"waitUntilPodsAreReady",
"(",
"final",
"T",
"obj",
",",
"final",
"String",
"namespace",
",",
"final",
"int",
"requiredPodCount",
")",
"{",
"final",
"CountDownLatch",
"countDownLatch",
"=",
"new",
"CountDownLatch",
"(",
"1",
")",
";",
"final",
... | Lets wait until there are enough Ready pods of the given RC | [
"Lets",
"wait",
"until",
"there",
"are",
"enough",
"Ready",
"pods",
"of",
"the",
"given",
"RC"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/internal/RollingUpdater.java#L176-L212 |
15,740 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/internal/readiness/Readiness.java | Readiness.getPodReadyCondition | private static PodCondition getPodReadyCondition(Pod pod) {
Utils.checkNotNull(pod, "Pod can't be null.");
if (pod.getStatus() == null || pod.getStatus().getConditions() == null) {
return null;
}
for (PodCondition condition : pod.getStatus().getConditions()) {
if (POD_READY.equals(conditio... | java | private static PodCondition getPodReadyCondition(Pod pod) {
Utils.checkNotNull(pod, "Pod can't be null.");
if (pod.getStatus() == null || pod.getStatus().getConditions() == null) {
return null;
}
for (PodCondition condition : pod.getStatus().getConditions()) {
if (POD_READY.equals(conditio... | [
"private",
"static",
"PodCondition",
"getPodReadyCondition",
"(",
"Pod",
"pod",
")",
"{",
"Utils",
".",
"checkNotNull",
"(",
"pod",
",",
"\"Pod can't be null.\"",
")",
";",
"if",
"(",
"pod",
".",
"getStatus",
"(",
")",
"==",
"null",
"||",
"pod",
".",
"getS... | Returns the ready condition of the pod.
@param pod The target pod.
@return The {@link PodCondition} or null if not found. | [
"Returns",
"the",
"ready",
"condition",
"of",
"the",
"pod",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/internal/readiness/Readiness.java#L206-L219 |
15,741 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/internal/readiness/Readiness.java | Readiness.getNodeReadyCondition | private static NodeCondition getNodeReadyCondition(Node node) {
Utils.checkNotNull(node, "Node can't be null.");
if (node.getStatus() == null || node.getStatus().getConditions() == null) {
return null;
}
for (NodeCondition condition : node.getStatus().getConditions()) {
if (NODE_READY.equa... | java | private static NodeCondition getNodeReadyCondition(Node node) {
Utils.checkNotNull(node, "Node can't be null.");
if (node.getStatus() == null || node.getStatus().getConditions() == null) {
return null;
}
for (NodeCondition condition : node.getStatus().getConditions()) {
if (NODE_READY.equa... | [
"private",
"static",
"NodeCondition",
"getNodeReadyCondition",
"(",
"Node",
"node",
")",
"{",
"Utils",
".",
"checkNotNull",
"(",
"node",
",",
"\"Node can't be null.\"",
")",
";",
"if",
"(",
"node",
".",
"getStatus",
"(",
")",
"==",
"null",
"||",
"node",
".",... | Returns the ready condition of the node.
@param node The target node.
@return The {@link NodeCondition} or null if not found. | [
"Returns",
"the",
"ready",
"condition",
"of",
"the",
"node",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/internal/readiness/Readiness.java#L236-L249 |
15,742 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java | KubernetesResourceUtil.getResourceVersion | public static String getResourceVersion(HasMetadata entity) {
if (entity != null) {
ObjectMeta metadata = entity.getMetadata();
if (metadata != null) {
String resourceVersion = metadata.getResourceVersion();
if (!Utils.isNullOrEmpty(resourceVersion)) {
return resourceVersion;
... | java | public static String getResourceVersion(HasMetadata entity) {
if (entity != null) {
ObjectMeta metadata = entity.getMetadata();
if (metadata != null) {
String resourceVersion = metadata.getResourceVersion();
if (!Utils.isNullOrEmpty(resourceVersion)) {
return resourceVersion;
... | [
"public",
"static",
"String",
"getResourceVersion",
"(",
"HasMetadata",
"entity",
")",
"{",
"if",
"(",
"entity",
"!=",
"null",
")",
"{",
"ObjectMeta",
"metadata",
"=",
"entity",
".",
"getMetadata",
"(",
")",
";",
"if",
"(",
"metadata",
"!=",
"null",
")",
... | Returns the resource version for the entity or null if it does not have one
@param entity entity provided
@return returns resource version of provided entity | [
"Returns",
"the",
"resource",
"version",
"for",
"the",
"entity",
"or",
"null",
"if",
"it",
"does",
"not",
"have",
"one"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java#L40-L51 |
15,743 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java | KubernetesResourceUtil.getKind | public static String getKind(HasMetadata entity) {
if (entity != null) {
// TODO use reflection to find the kind?
if (entity instanceof KubernetesList) {
return "List";
} else {
return entity.getClass().getSimpleName();
}
} else {
return null;
}
} | java | public static String getKind(HasMetadata entity) {
if (entity != null) {
// TODO use reflection to find the kind?
if (entity instanceof KubernetesList) {
return "List";
} else {
return entity.getClass().getSimpleName();
}
} else {
return null;
}
} | [
"public",
"static",
"String",
"getKind",
"(",
"HasMetadata",
"entity",
")",
"{",
"if",
"(",
"entity",
"!=",
"null",
")",
"{",
"// TODO use reflection to find the kind?",
"if",
"(",
"entity",
"instanceof",
"KubernetesList",
")",
"{",
"return",
"\"List\"",
";",
"}... | Returns the kind of the entity
@param entity provided entity
@return returns kind of entity provided | [
"Returns",
"the",
"kind",
"of",
"the",
"entity"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java#L59-L70 |
15,744 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java | KubernetesResourceUtil.getQualifiedName | public static String getQualifiedName(HasMetadata entity) {
if (entity != null) {
return "" + getNamespace(entity) + "/" + getName(entity);
} else {
return null;
}
} | java | public static String getQualifiedName(HasMetadata entity) {
if (entity != null) {
return "" + getNamespace(entity) + "/" + getName(entity);
} else {
return null;
}
} | [
"public",
"static",
"String",
"getQualifiedName",
"(",
"HasMetadata",
"entity",
")",
"{",
"if",
"(",
"entity",
"!=",
"null",
")",
"{",
"return",
"\"\"",
"+",
"getNamespace",
"(",
"entity",
")",
"+",
"\"/\"",
"+",
"getName",
"(",
"entity",
")",
";",
"}",
... | Returns Qualified name for the specified Kubernetes Resource
@param entity Kubernetes resource
@return returns qualified name | [
"Returns",
"Qualified",
"name",
"for",
"the",
"specified",
"Kubernetes",
"Resource"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java#L78-L84 |
15,745 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java | KubernetesResourceUtil.getNamespace | public static String getNamespace(HasMetadata entity) {
if (entity != null) {
return getNamespace(entity.getMetadata());
} else {
return null;
}
} | java | public static String getNamespace(HasMetadata entity) {
if (entity != null) {
return getNamespace(entity.getMetadata());
} else {
return null;
}
} | [
"public",
"static",
"String",
"getNamespace",
"(",
"HasMetadata",
"entity",
")",
"{",
"if",
"(",
"entity",
"!=",
"null",
")",
"{",
"return",
"getNamespace",
"(",
"entity",
".",
"getMetadata",
"(",
")",
")",
";",
"}",
"else",
"{",
"return",
"null",
";",
... | Getting namespace from Kubernetes Resource
@param entity Kubernetes Resource
@return returns namespace as plain string | [
"Getting",
"namespace",
"from",
"Kubernetes",
"Resource"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java#L163-L169 |
15,746 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java | KubernetesResourceUtil.getOrCreateLabels | public static Map<String, String> getOrCreateLabels(HasMetadata entity) {
ObjectMeta metadata = getOrCreateMetadata(entity);
Map<String, String> answer = metadata.getLabels();
if (answer == null) {
// use linked so the annotations can be in the FIFO order
answer = new LinkedHashMap<>();
me... | java | public static Map<String, String> getOrCreateLabels(HasMetadata entity) {
ObjectMeta metadata = getOrCreateMetadata(entity);
Map<String, String> answer = metadata.getLabels();
if (answer == null) {
// use linked so the annotations can be in the FIFO order
answer = new LinkedHashMap<>();
me... | [
"public",
"static",
"Map",
"<",
"String",
",",
"String",
">",
"getOrCreateLabels",
"(",
"HasMetadata",
"entity",
")",
"{",
"ObjectMeta",
"metadata",
"=",
"getOrCreateMetadata",
"(",
"entity",
")",
";",
"Map",
"<",
"String",
",",
"String",
">",
"answer",
"=",... | Null safe get method for getting Labels of a Kubernetes Resource
@param entity Kubernetes Resource
@return returns a hashmap containing labels | [
"Null",
"safe",
"get",
"method",
"for",
"getting",
"Labels",
"of",
"a",
"Kubernetes",
"Resource"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java#L207-L216 |
15,747 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java | KubernetesResourceUtil.getLabels | @SuppressWarnings("unchecked")
public static Map<String, String> getLabels(ObjectMeta metadata) {
if (metadata != null) {
Map<String, String> labels = metadata.getLabels();
if (labels != null) {
return labels;
}
}
return Collections.EMPTY_MAP;
} | java | @SuppressWarnings("unchecked")
public static Map<String, String> getLabels(ObjectMeta metadata) {
if (metadata != null) {
Map<String, String> labels = metadata.getLabels();
if (labels != null) {
return labels;
}
}
return Collections.EMPTY_MAP;
} | [
"@",
"SuppressWarnings",
"(",
"\"unchecked\"",
")",
"public",
"static",
"Map",
"<",
"String",
",",
"String",
">",
"getLabels",
"(",
"ObjectMeta",
"metadata",
")",
"{",
"if",
"(",
"metadata",
"!=",
"null",
")",
"{",
"Map",
"<",
"String",
",",
"String",
">... | Returns the labels of the given metadata object or an empty map if the metadata or labels are null
@param metadata ObjectMeta for resource's metadata
@return returns labels as a hashmap | [
"Returns",
"the",
"labels",
"of",
"the",
"given",
"metadata",
"object",
"or",
"an",
"empty",
"map",
"if",
"the",
"metadata",
"or",
"labels",
"are",
"null"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java#L225-L234 |
15,748 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java | KubernetesResourceUtil.isValidName | public static boolean isValidName(String name) {
return Utils.isNotNullOrEmpty(name) &&
name.length() < KUBERNETES_DNS1123_LABEL_MAX_LENGTH &&
KUBERNETES_DNS1123_LABEL_REGEX.matcher(name).matches();
} | java | public static boolean isValidName(String name) {
return Utils.isNotNullOrEmpty(name) &&
name.length() < KUBERNETES_DNS1123_LABEL_MAX_LENGTH &&
KUBERNETES_DNS1123_LABEL_REGEX.matcher(name).matches();
} | [
"public",
"static",
"boolean",
"isValidName",
"(",
"String",
"name",
")",
"{",
"return",
"Utils",
".",
"isNotNullOrEmpty",
"(",
"name",
")",
"&&",
"name",
".",
"length",
"(",
")",
"<",
"KUBERNETES_DNS1123_LABEL_MAX_LENGTH",
"&&",
"KUBERNETES_DNS1123_LABEL_REGEX",
... | Validates name of Kubernetes Resource name, label or annotation based on Kubernetes regex
@param name Name of resource/label/annotation
@return returns a boolean value indicating whether it's valid or not | [
"Validates",
"name",
"of",
"Kubernetes",
"Resource",
"name",
"label",
"or",
"annotation",
"based",
"on",
"Kubernetes",
"regex"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/KubernetesResourceUtil.java#L257-L261 |
15,749 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/ReplaceValueStream.java | ReplaceValueStream.replaceValues | public static InputStream replaceValues(InputStream is, Map<String, String> valuesMap) {
return new ReplaceValueStream(valuesMap).createInputStream(is);
} | java | public static InputStream replaceValues(InputStream is, Map<String, String> valuesMap) {
return new ReplaceValueStream(valuesMap).createInputStream(is);
} | [
"public",
"static",
"InputStream",
"replaceValues",
"(",
"InputStream",
"is",
",",
"Map",
"<",
"String",
",",
"String",
">",
"valuesMap",
")",
"{",
"return",
"new",
"ReplaceValueStream",
"(",
"valuesMap",
")",
".",
"createInputStream",
"(",
"is",
")",
";",
"... | Returns a stream with the template parameter expressions replaced
@param is {@link InputStream} inputstream for
@param valuesMap a hashmap containing parameters
@return returns stream with template parameter expressions replaced | [
"Returns",
"a",
"stream",
"with",
"the",
"template",
"parameter",
"expressions",
"replaced"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/ReplaceValueStream.java#L39-L41 |
15,750 | fabric8io/kubernetes-client | kubernetes-model/kubernetes-model/src/main/java/io/fabric8/kubernetes/internal/KubernetesDeserializer.java | KubernetesDeserializer.getKey | private static final String getKey(String apiVersion, String kind) {
if (kind == null) {
return null;
} else if (apiVersion == null) {
return kind;
} else {
return String.format("%s#%s", apiVersion, kind);
}
} | java | private static final String getKey(String apiVersion, String kind) {
if (kind == null) {
return null;
} else if (apiVersion == null) {
return kind;
} else {
return String.format("%s#%s", apiVersion, kind);
}
} | [
"private",
"static",
"final",
"String",
"getKey",
"(",
"String",
"apiVersion",
",",
"String",
"kind",
")",
"{",
"if",
"(",
"kind",
"==",
"null",
")",
"{",
"return",
"null",
";",
"}",
"else",
"if",
"(",
"apiVersion",
"==",
"null",
")",
"{",
"return",
... | Returns a composite key for apiVersion and kind. | [
"Returns",
"a",
"composite",
"key",
"for",
"apiVersion",
"and",
"kind",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-model/kubernetes-model/src/main/java/io/fabric8/kubernetes/internal/KubernetesDeserializer.java#L100-L108 |
15,751 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/internal/KubeConfigUtils.java | KubeConfigUtils.getUserToken | public static String getUserToken(Config config, Context context) {
AuthInfo authInfo = getUserAuthInfo(config, context);
if (authInfo != null) {
return authInfo.getToken();
}
return null;
} | java | public static String getUserToken(Config config, Context context) {
AuthInfo authInfo = getUserAuthInfo(config, context);
if (authInfo != null) {
return authInfo.getToken();
}
return null;
} | [
"public",
"static",
"String",
"getUserToken",
"(",
"Config",
"config",
",",
"Context",
"context",
")",
"{",
"AuthInfo",
"authInfo",
"=",
"getUserAuthInfo",
"(",
"config",
",",
"context",
")",
";",
"if",
"(",
"authInfo",
"!=",
"null",
")",
"{",
"return",
"a... | Returns the current user token for the config and current context
@param config Config object
@param context Context object
@return returns current user based upon provided parameters. | [
"Returns",
"the",
"current",
"user",
"token",
"for",
"the",
"config",
"and",
"current",
"context"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/internal/KubeConfigUtils.java#L78-L84 |
15,752 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/internal/NamespaceVisitFromServerGetWatchDeleteRecreateWaitApplicableListImpl.java | NamespaceVisitFromServerGetWatchDeleteRecreateWaitApplicableListImpl.checkConditionMetForAll | private static boolean checkConditionMetForAll(CountDownLatch latch, int expected, AtomicInteger actual, long amount, TimeUnit timeUnit) {
try {
if (latch.await(amount, timeUnit)) {
return actual.intValue() == expected;
}
return false;
} catch (InterruptedException e) {
Thread.cu... | java | private static boolean checkConditionMetForAll(CountDownLatch latch, int expected, AtomicInteger actual, long amount, TimeUnit timeUnit) {
try {
if (latch.await(amount, timeUnit)) {
return actual.intValue() == expected;
}
return false;
} catch (InterruptedException e) {
Thread.cu... | [
"private",
"static",
"boolean",
"checkConditionMetForAll",
"(",
"CountDownLatch",
"latch",
",",
"int",
"expected",
",",
"AtomicInteger",
"actual",
",",
"long",
"amount",
",",
"TimeUnit",
"timeUnit",
")",
"{",
"try",
"{",
"if",
"(",
"latch",
".",
"await",
"(",
... | Waits until the latch reaches to zero and then checks if the expected result
@param latch The latch.
@param expected The expected number.
@param actual The actual number.
@param amount The amount of time to wait.
@param timeUnit The timeUnit.
@return | [
"Waits",
"until",
"the",
"latch",
"reaches",
"to",
"zero",
"and",
"then",
"checks",
"if",
"the",
"expected",
"result"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/internal/NamespaceVisitFromServerGetWatchDeleteRecreateWaitApplicableListImpl.java#L421-L431 |
15,753 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/HasMetadataOperation.java | HasMetadataOperation.periodicWatchUntilReady | protected T periodicWatchUntilReady(int i, long started, long interval, long amount) {
T item = fromServer().get();
if (Readiness.isReady(item)) {
return item;
}
ReadinessWatcher<T> watcher = new ReadinessWatcher<>(item);
try (Watch watch = watch(item.getMetadata().getResourceVersion(), watch... | java | protected T periodicWatchUntilReady(int i, long started, long interval, long amount) {
T item = fromServer().get();
if (Readiness.isReady(item)) {
return item;
}
ReadinessWatcher<T> watcher = new ReadinessWatcher<>(item);
try (Watch watch = watch(item.getMetadata().getResourceVersion(), watch... | [
"protected",
"T",
"periodicWatchUntilReady",
"(",
"int",
"i",
",",
"long",
"started",
",",
"long",
"interval",
",",
"long",
"amount",
")",
"{",
"T",
"item",
"=",
"fromServer",
"(",
")",
".",
"get",
"(",
")",
";",
"if",
"(",
"Readiness",
".",
"isReady",... | A wait method that combines watching and polling.
The need for that is that in some cases a pure watcher approach consistently fails.
@param i The number of iterations to perform.
@param started Time in milliseconds where the watch started.
@param interval The amount of time in millis to wait on each i... | [
"A",
"wait",
"method",
"that",
"combines",
"watching",
"and",
"polling",
".",
"The",
"need",
"for",
"that",
"is",
"that",
"in",
"some",
"cases",
"a",
"pure",
"watcher",
"approach",
"consistently",
"fails",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/HasMetadataOperation.java#L183-L203 |
15,754 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/Utils.java | Utils.replaceAllWithoutRegex | public static String replaceAllWithoutRegex(String text, String from, String to) {
if (text == null) {
return null;
}
int idx = 0;
while (true) {
idx = text.indexOf(from, idx);
if (idx >= 0) {
text = text.substring(0, idx) + to + text.substring(idx + from.length());
//... | java | public static String replaceAllWithoutRegex(String text, String from, String to) {
if (text == null) {
return null;
}
int idx = 0;
while (true) {
idx = text.indexOf(from, idx);
if (idx >= 0) {
text = text.substring(0, idx) + to + text.substring(idx + from.length());
//... | [
"public",
"static",
"String",
"replaceAllWithoutRegex",
"(",
"String",
"text",
",",
"String",
"from",
",",
"String",
"to",
")",
"{",
"if",
"(",
"text",
"==",
"null",
")",
"{",
"return",
"null",
";",
"}",
"int",
"idx",
"=",
"0",
";",
"while",
"(",
"tr... | Replaces all occurrences of the from text with to text without any regular expressions
@param text text string
@param from from string
@param to to string
@return returns processed string | [
"Replaces",
"all",
"occurrences",
"of",
"the",
"from",
"text",
"with",
"to",
"text",
"without",
"any",
"regular",
"expressions"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/Utils.java#L260-L277 |
15,755 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/Utils.java | Utils.toUrlEncoded | public static final String toUrlEncoded(String str) {
try {
return URLEncoder.encode(str, "UTF-8");
} catch (UnsupportedEncodingException exception) {
// Ignore
}
return null;
} | java | public static final String toUrlEncoded(String str) {
try {
return URLEncoder.encode(str, "UTF-8");
} catch (UnsupportedEncodingException exception) {
// Ignore
}
return null;
} | [
"public",
"static",
"final",
"String",
"toUrlEncoded",
"(",
"String",
"str",
")",
"{",
"try",
"{",
"return",
"URLEncoder",
".",
"encode",
"(",
"str",
",",
"\"UTF-8\"",
")",
";",
"}",
"catch",
"(",
"UnsupportedEncodingException",
"exception",
")",
"{",
"// Ig... | Converts string to URL encoded string.
@param str Url as string
@return returns encoded string | [
"Converts",
"string",
"to",
"URL",
"encoded",
"string",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/utils/Utils.java#L314-L321 |
15,756 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/BaseOperation.java | BaseOperation.name | private static <T> String name(T item, String name) {
if (name != null && !name.isEmpty()) {
return name;
} else if (item instanceof HasMetadata) {
HasMetadata h = (HasMetadata) item;
return h.getMetadata() != null ? h.getMetadata().getName() : null;
}
return null;
} | java | private static <T> String name(T item, String name) {
if (name != null && !name.isEmpty()) {
return name;
} else if (item instanceof HasMetadata) {
HasMetadata h = (HasMetadata) item;
return h.getMetadata() != null ? h.getMetadata().getName() : null;
}
return null;
} | [
"private",
"static",
"<",
"T",
">",
"String",
"name",
"(",
"T",
"item",
",",
"String",
"name",
")",
"{",
"if",
"(",
"name",
"!=",
"null",
"&&",
"!",
"name",
".",
"isEmpty",
"(",
")",
")",
"{",
"return",
"name",
";",
"}",
"else",
"if",
"(",
"ite... | Returns the name and falls back to the item name.
@param item The item.
@param name The name to check.
@param <T>
@return | [
"Returns",
"the",
"name",
"and",
"falls",
"back",
"to",
"the",
"item",
"name",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/BaseOperation.java#L115-L123 |
15,757 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/BaseOperation.java | BaseOperation.updateApiVersionResource | protected void updateApiVersionResource(Object resource) {
if (resource instanceof HasMetadata) {
HasMetadata hasMetadata = (HasMetadata) resource;
updateApiVersion(hasMetadata);
} else if (resource instanceof KubernetesResourceList) {
KubernetesResourceList list = (KubernetesResourceList) res... | java | protected void updateApiVersionResource(Object resource) {
if (resource instanceof HasMetadata) {
HasMetadata hasMetadata = (HasMetadata) resource;
updateApiVersion(hasMetadata);
} else if (resource instanceof KubernetesResourceList) {
KubernetesResourceList list = (KubernetesResourceList) res... | [
"protected",
"void",
"updateApiVersionResource",
"(",
"Object",
"resource",
")",
"{",
"if",
"(",
"resource",
"instanceof",
"HasMetadata",
")",
"{",
"HasMetadata",
"hasMetadata",
"=",
"(",
"HasMetadata",
")",
"resource",
";",
"updateApiVersion",
"(",
"hasMetadata",
... | Updates the list or single item if it has a missing or incorrect apiGroupVersion
@param resource resource object | [
"Updates",
"the",
"list",
"or",
"single",
"item",
"if",
"it",
"has",
"a",
"missing",
"or",
"incorrect",
"apiGroupVersion"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/BaseOperation.java#L853-L861 |
15,758 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/BaseOperation.java | BaseOperation.updateApiVersion | protected void updateApiVersion(KubernetesResourceList list) {
String version = getApiVersion();
if (list != null && version != null && version.length() > 0) {
List items = list.getItems();
if (items != null) {
for (Object item : items) {
if (item instanceof HasMetadata) {
... | java | protected void updateApiVersion(KubernetesResourceList list) {
String version = getApiVersion();
if (list != null && version != null && version.length() > 0) {
List items = list.getItems();
if (items != null) {
for (Object item : items) {
if (item instanceof HasMetadata) {
... | [
"protected",
"void",
"updateApiVersion",
"(",
"KubernetesResourceList",
"list",
")",
"{",
"String",
"version",
"=",
"getApiVersion",
"(",
")",
";",
"if",
"(",
"list",
"!=",
"null",
"&&",
"version",
"!=",
"null",
"&&",
"version",
".",
"length",
"(",
")",
">... | Updates the list items if they have missing or default apiGroupVersion values and the resource is currently
using API Groups with custom version strings
@param list Kubernetes resource list | [
"Updates",
"the",
"list",
"items",
"if",
"they",
"have",
"missing",
"or",
"default",
"apiGroupVersion",
"values",
"and",
"the",
"resource",
"is",
"currently",
"using",
"API",
"Groups",
"with",
"custom",
"version",
"strings"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/BaseOperation.java#L869-L881 |
15,759 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/BaseOperation.java | BaseOperation.updateApiVersion | protected void updateApiVersion(HasMetadata hasMetadata) {
String version = getApiVersion();
if (hasMetadata != null && version != null && version.length() > 0) {
String current = hasMetadata.getApiVersion();
// lets overwrite the api version if its currently missing, the resource uses an API Group ... | java | protected void updateApiVersion(HasMetadata hasMetadata) {
String version = getApiVersion();
if (hasMetadata != null && version != null && version.length() > 0) {
String current = hasMetadata.getApiVersion();
// lets overwrite the api version if its currently missing, the resource uses an API Group ... | [
"protected",
"void",
"updateApiVersion",
"(",
"HasMetadata",
"hasMetadata",
")",
"{",
"String",
"version",
"=",
"getApiVersion",
"(",
")",
";",
"if",
"(",
"hasMetadata",
"!=",
"null",
"&&",
"version",
"!=",
"null",
"&&",
"version",
".",
"length",
"(",
")",
... | Updates the resource if it has missing or default apiGroupVersion values and the resource is currently
using API Groups with custom version strings
@param hasMetadata object whose api version needs to be updated | [
"Updates",
"the",
"resource",
"if",
"it",
"has",
"missing",
"or",
"default",
"apiGroupVersion",
"values",
"and",
"the",
"resource",
"is",
"currently",
"using",
"API",
"Groups",
"with",
"custom",
"version",
"strings"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/BaseOperation.java#L890-L900 |
15,760 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java | OperationSupport.handleCreate | protected <T, I> T handleCreate(I resource, Class<T> outputType) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
RequestBody body = RequestBody.create(JSON, JSON_MAPPER.writeValueAsString(resource));
Request.Builder requestBuilder = new Request.Builder().post(body).url(... | java | protected <T, I> T handleCreate(I resource, Class<T> outputType) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
RequestBody body = RequestBody.create(JSON, JSON_MAPPER.writeValueAsString(resource));
Request.Builder requestBuilder = new Request.Builder().post(body).url(... | [
"protected",
"<",
"T",
",",
"I",
">",
"T",
"handleCreate",
"(",
"I",
"resource",
",",
"Class",
"<",
"T",
">",
"outputType",
")",
"throws",
"ExecutionException",
",",
"InterruptedException",
",",
"KubernetesClientException",
",",
"IOException",
"{",
"RequestBody"... | Create a resource.
@param resource resource provided
@param outputType resource type you want as output
@param <T> template argument for output type
@param <I> template argument for resource
@return returns de-serialized version of apiserver response in form of type provided
@throws ExecutionException Execution Excep... | [
"Create",
"a",
"resource",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java#L231-L235 |
15,761 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java | OperationSupport.handleReplace | protected <T> T handleReplace(T updated, Class<T> type) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
return handleReplace(updated, type, Collections.<String, String>emptyMap());
} | java | protected <T> T handleReplace(T updated, Class<T> type) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
return handleReplace(updated, type, Collections.<String, String>emptyMap());
} | [
"protected",
"<",
"T",
">",
"T",
"handleReplace",
"(",
"T",
"updated",
",",
"Class",
"<",
"T",
">",
"type",
")",
"throws",
"ExecutionException",
",",
"InterruptedException",
",",
"KubernetesClientException",
",",
"IOException",
"{",
"return",
"handleReplace",
"(... | Replace a resource.
@param updated updated object
@param type type of the object provided
@param <T> template argument provided
@return returns de-serialized version of api server response
@throws ExecutionException Execution Exception
@throws InterruptedException Interrupted Exception
@throws KubernetesClientExcepti... | [
"Replace",
"a",
"resource",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java#L251-L253 |
15,762 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java | OperationSupport.handleReplace | protected <T> T handleReplace(T updated, Class<T> type, Map<String, String> parameters) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
RequestBody body = RequestBody.create(JSON, JSON_MAPPER.writeValueAsString(updated));
Request.Builder requestBuilder = new Request.Bui... | java | protected <T> T handleReplace(T updated, Class<T> type, Map<String, String> parameters) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
RequestBody body = RequestBody.create(JSON, JSON_MAPPER.writeValueAsString(updated));
Request.Builder requestBuilder = new Request.Bui... | [
"protected",
"<",
"T",
">",
"T",
"handleReplace",
"(",
"T",
"updated",
",",
"Class",
"<",
"T",
">",
"type",
",",
"Map",
"<",
"String",
",",
"String",
">",
"parameters",
")",
"throws",
"ExecutionException",
",",
"InterruptedException",
",",
"KubernetesClientE... | Replace a resource, optionally performing placeholder substitution to the response.
@param updated updated object
@param type type of object provided
@param parameters a HashMap containing parameters for processing object
@param <T> template argument provided
@return returns de-serialized version of api server respon... | [
"Replace",
"a",
"resource",
"optionally",
"performing",
"placeholder",
"substitution",
"to",
"the",
"response",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java#L269-L273 |
15,763 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java | OperationSupport.handlePatch | protected <T> T handlePatch(T current, T updated, Class<T> type) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
JsonNode diff = JsonDiff.asJson(patchMapper().valueToTree(current), patchMapper().valueToTree(updated));
RequestBody body = RequestBody.create(JSON_PATCH, JS... | java | protected <T> T handlePatch(T current, T updated, Class<T> type) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
JsonNode diff = JsonDiff.asJson(patchMapper().valueToTree(current), patchMapper().valueToTree(updated));
RequestBody body = RequestBody.create(JSON_PATCH, JS... | [
"protected",
"<",
"T",
">",
"T",
"handlePatch",
"(",
"T",
"current",
",",
"T",
"updated",
",",
"Class",
"<",
"T",
">",
"type",
")",
"throws",
"ExecutionException",
",",
"InterruptedException",
",",
"KubernetesClientException",
",",
"IOException",
"{",
"JsonNod... | Send an http patch and handle the response.
@param current current object
@param updated updated object
@param type type of object
@param <T> template argument provided
@return returns de-serialized version of api server response
@throws ExecutionException Execution Exception
@throws InterruptedException Interrupted ... | [
"Send",
"an",
"http",
"patch",
"and",
"handle",
"the",
"response",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java#L289-L294 |
15,764 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java | OperationSupport.handleGet | protected <T> T handleGet(URL resourceUrl, Class<T> type) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
return handleGet(resourceUrl, type, Collections.<String, String>emptyMap());
} | java | protected <T> T handleGet(URL resourceUrl, Class<T> type) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
return handleGet(resourceUrl, type, Collections.<String, String>emptyMap());
} | [
"protected",
"<",
"T",
">",
"T",
"handleGet",
"(",
"URL",
"resourceUrl",
",",
"Class",
"<",
"T",
">",
"type",
")",
"throws",
"ExecutionException",
",",
"InterruptedException",
",",
"KubernetesClientException",
",",
"IOException",
"{",
"return",
"handleGet",
"(",... | Send an http get.
@param resourceUrl resource URL to be processed
@param type type of resource
@param <T> template argument provided
@return returns a deserialized object as api server response of provided type.
@throws ExecutionException Execution Exception
@throws InterruptedException Interrupted Exception
@throws ... | [
"Send",
"an",
"http",
"get",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java#L310-L312 |
15,765 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java | OperationSupport.handleGet | protected <T> T handleGet(URL resourceUrl, Class<T> type, Map<String, String> parameters) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
Request.Builder requestBuilder = new Request.Builder().get().url(resourceUrl);
return handleResponse(requestBuilder, type, parameter... | java | protected <T> T handleGet(URL resourceUrl, Class<T> type, Map<String, String> parameters) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
Request.Builder requestBuilder = new Request.Builder().get().url(resourceUrl);
return handleResponse(requestBuilder, type, parameter... | [
"protected",
"<",
"T",
">",
"T",
"handleGet",
"(",
"URL",
"resourceUrl",
",",
"Class",
"<",
"T",
">",
"type",
",",
"Map",
"<",
"String",
",",
"String",
">",
"parameters",
")",
"throws",
"ExecutionException",
",",
"InterruptedException",
",",
"KubernetesClien... | Send an http, optionally performing placeholder substitution to the response.
@param resourceUrl resource URL to be processed
@param type type of resource
@param parameters A HashMap of strings containing parameters to be passed in request
@param <T> template argument provided
@return Returns a deserialized object as... | [
"Send",
"an",
"http",
"optionally",
"performing",
"placeholder",
"substitution",
"to",
"the",
"response",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java#L328-L331 |
15,766 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java | OperationSupport.handleResponse | protected <T> T handleResponse(Request.Builder requestBuilder, Class<T> type) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
return handleResponse(requestBuilder, type, Collections.<String, String>emptyMap());
} | java | protected <T> T handleResponse(Request.Builder requestBuilder, Class<T> type) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
return handleResponse(requestBuilder, type, Collections.<String, String>emptyMap());
} | [
"protected",
"<",
"T",
">",
"T",
"handleResponse",
"(",
"Request",
".",
"Builder",
"requestBuilder",
",",
"Class",
"<",
"T",
">",
"type",
")",
"throws",
"ExecutionException",
",",
"InterruptedException",
",",
"KubernetesClientException",
",",
"IOException",
"{",
... | Send an http request and handle the response.
@param requestBuilder Request Builder object
@param type type of resource
@param <T> template argument provided
@return Returns a de-serialized object as api server response of provided type.
@throws ExecutionException Execution Exception
@throws InterruptedException Inte... | [
"Send",
"an",
"http",
"request",
"and",
"handle",
"the",
"response",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java#L346-L348 |
15,767 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java | OperationSupport.handleResponse | protected <T> T handleResponse(OkHttpClient client, Request.Builder requestBuilder, Class<T> type, Map<String, String> parameters) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
VersionUsageUtils.log(this.resourceT, this.apiGroupVersion);
Request request = requestBuild... | java | protected <T> T handleResponse(OkHttpClient client, Request.Builder requestBuilder, Class<T> type, Map<String, String> parameters) throws ExecutionException, InterruptedException, KubernetesClientException, IOException {
VersionUsageUtils.log(this.resourceT, this.apiGroupVersion);
Request request = requestBuild... | [
"protected",
"<",
"T",
">",
"T",
"handleResponse",
"(",
"OkHttpClient",
"client",
",",
"Request",
".",
"Builder",
"requestBuilder",
",",
"Class",
"<",
"T",
">",
"type",
",",
"Map",
"<",
"String",
",",
"String",
">",
"parameters",
")",
"throws",
"ExecutionE... | Send an http request and handle the response, optionally performing placeholder substitution to the response.
@param client OkHttp client provided
@param requestBuilder Request builder
@param type Type of object provided
@param parameters A hashmap containing parameters
@p... | [
"Send",
"an",
"http",
"request",
"and",
"handle",
"the",
"response",
"optionally",
"performing",
"placeholder",
"substitution",
"to",
"the",
"response",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java#L401-L424 |
15,768 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java | OperationSupport.assertResponseCode | protected void assertResponseCode(Request request, Response response) {
int statusCode = response.code();
String customMessage = config.getErrorMessages().get(statusCode);
if (response.isSuccessful()) {
return;
} else if (customMessage != null) {
throw requestFailure(request, createStatus(s... | java | protected void assertResponseCode(Request request, Response response) {
int statusCode = response.code();
String customMessage = config.getErrorMessages().get(statusCode);
if (response.isSuccessful()) {
return;
} else if (customMessage != null) {
throw requestFailure(request, createStatus(s... | [
"protected",
"void",
"assertResponseCode",
"(",
"Request",
"request",
",",
"Response",
"response",
")",
"{",
"int",
"statusCode",
"=",
"response",
".",
"code",
"(",
")",
";",
"String",
"customMessage",
"=",
"config",
".",
"getErrorMessages",
"(",
")",
".",
"... | Checks if the response status code is the expected and throws the appropriate KubernetesClientException if not.
@param request The {#link Request} object.
@param response The {@link Response} object.
@throws KubernetesClientException When the response code is not the expected. | [
"Checks",
"if",
"the",
"response",
"status",
"code",
"is",
"the",
"expected",
"and",
"throws",
"the",
"appropriate",
"KubernetesClientException",
"if",
"not",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/base/OperationSupport.java#L433-L444 |
15,769 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/internal/JobOperationsImpl.java | JobOperationsImpl.waitUntilJobIsScaled | private void waitUntilJobIsScaled() {
final CountDownLatch countDownLatch = new CountDownLatch(1);
final AtomicReference<Job> atomicJob = new AtomicReference<>();
final Runnable jobPoller = () -> {
try {
Job job = getMandatory();
atomicJob.set(job);
Integer activeJobs = job.g... | java | private void waitUntilJobIsScaled() {
final CountDownLatch countDownLatch = new CountDownLatch(1);
final AtomicReference<Job> atomicJob = new AtomicReference<>();
final Runnable jobPoller = () -> {
try {
Job job = getMandatory();
atomicJob.set(job);
Integer activeJobs = job.g... | [
"private",
"void",
"waitUntilJobIsScaled",
"(",
")",
"{",
"final",
"CountDownLatch",
"countDownLatch",
"=",
"new",
"CountDownLatch",
"(",
"1",
")",
";",
"final",
"AtomicReference",
"<",
"Job",
">",
"atomicJob",
"=",
"new",
"AtomicReference",
"<>",
"(",
")",
";... | Lets wait until there are enough Ready pods of the given Job | [
"Lets",
"wait",
"until",
"there",
"are",
"enough",
"Ready",
"pods",
"of",
"the",
"given",
"Job"
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/internal/JobOperationsImpl.java#L97-L133 |
15,770 | fabric8io/kubernetes-client | kubernetes-client/src/main/java/io/fabric8/kubernetes/client/Config.java | Config.autoConfigure | public static Config autoConfigure(String context) {
Config config = new Config();
return autoConfigure(config, context);
} | java | public static Config autoConfigure(String context) {
Config config = new Config();
return autoConfigure(config, context);
} | [
"public",
"static",
"Config",
"autoConfigure",
"(",
"String",
"context",
")",
"{",
"Config",
"config",
"=",
"new",
"Config",
"(",
")",
";",
"return",
"autoConfigure",
"(",
"config",
",",
"context",
")",
";",
"}"
] | Does auto detection with some opinionated defaults.
@param context if null will use current-context
@return Config object | [
"Does",
"auto",
"detection",
"with",
"some",
"opinionated",
"defaults",
"."
] | 141668a882ed8e902c045a5cd0a80f14bd17d132 | https://github.com/fabric8io/kubernetes-client/blob/141668a882ed8e902c045a5cd0a80f14bd17d132/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/Config.java#L209-L212 |
15,771 | yidongnan/grpc-spring-boot-starter | grpc-common-spring-boot/src/main/java/net/devh/boot/grpc/common/metric/MetricUtils.java | MetricUtils.prepareCounterFor | public static Counter.Builder prepareCounterFor(final MethodDescriptor<?, ?> method,
final String name, final String description) {
return Counter.builder(name)
.description(description)
.baseUnit("messages")
.tag(TAG_SERVICE_NAME, extractServiceName(m... | java | public static Counter.Builder prepareCounterFor(final MethodDescriptor<?, ?> method,
final String name, final String description) {
return Counter.builder(name)
.description(description)
.baseUnit("messages")
.tag(TAG_SERVICE_NAME, extractServiceName(m... | [
"public",
"static",
"Counter",
".",
"Builder",
"prepareCounterFor",
"(",
"final",
"MethodDescriptor",
"<",
"?",
",",
"?",
">",
"method",
",",
"final",
"String",
"name",
",",
"final",
"String",
"description",
")",
"{",
"return",
"Counter",
".",
"builder",
"("... | Creates a new counter builder for the given method. By default the base unit will be messages.
@param method The method the counter will be created for.
@param name The name of the counter to use.
@param description The description of the counter to use.
@return The newly created counter builder. | [
"Creates",
"a",
"new",
"counter",
"builder",
"for",
"the",
"given",
"method",
".",
"By",
"default",
"the",
"base",
"unit",
"will",
"be",
"messages",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-common-spring-boot/src/main/java/net/devh/boot/grpc/common/metric/MetricUtils.java#L45-L52 |
15,772 | yidongnan/grpc-spring-boot-starter | grpc-common-spring-boot/src/main/java/net/devh/boot/grpc/common/metric/MetricUtils.java | MetricUtils.prepareTimerFor | public static Timer.Builder prepareTimerFor(final MethodDescriptor<?, ?> method,
final String name, final String description) {
return Timer.builder(name)
.description(description)
.tag(TAG_SERVICE_NAME, extractServiceName(method))
.tag(TAG_METHOD_NAME... | java | public static Timer.Builder prepareTimerFor(final MethodDescriptor<?, ?> method,
final String name, final String description) {
return Timer.builder(name)
.description(description)
.tag(TAG_SERVICE_NAME, extractServiceName(method))
.tag(TAG_METHOD_NAME... | [
"public",
"static",
"Timer",
".",
"Builder",
"prepareTimerFor",
"(",
"final",
"MethodDescriptor",
"<",
"?",
",",
"?",
">",
"method",
",",
"final",
"String",
"name",
",",
"final",
"String",
"description",
")",
"{",
"return",
"Timer",
".",
"builder",
"(",
"n... | Creates a new timer builder for the given method.
@param method The method the timer will be created for.
@param name The name of the timer to use.
@param description The description of the timer to use.
@return The newly created timer builder. | [
"Creates",
"a",
"new",
"timer",
"builder",
"for",
"the",
"given",
"method",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-common-spring-boot/src/main/java/net/devh/boot/grpc/common/metric/MetricUtils.java#L62-L68 |
15,773 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/security/authentication/X509CertificateAuthenticationProvider.java | X509CertificateAuthenticationProvider.patternExtractor | public static Function<X509CertificateAuthentication, String> patternExtractor(final String key,
final Function<? super X509CertificateAuthentication, String> fallback) {
requireNonNull(key, "key");
requireNonNull(fallback, "fallback");
final Pattern pattern = Pattern.compile(key + "... | java | public static Function<X509CertificateAuthentication, String> patternExtractor(final String key,
final Function<? super X509CertificateAuthentication, String> fallback) {
requireNonNull(key, "key");
requireNonNull(fallback, "fallback");
final Pattern pattern = Pattern.compile(key + "... | [
"public",
"static",
"Function",
"<",
"X509CertificateAuthentication",
",",
"String",
">",
"patternExtractor",
"(",
"final",
"String",
"key",
",",
"final",
"Function",
"<",
"?",
"super",
"X509CertificateAuthentication",
",",
"String",
">",
"fallback",
")",
"{",
"re... | Creates a new case-insensitive pattern extractor with the given pattern.
@param key The case insensitive key to use (Example: 'CN').
@param fallback The fallback function to use if the key was not present in the subject.
@return The newly created extractor. | [
"Creates",
"a",
"new",
"case",
"-",
"insensitive",
"pattern",
"extractor",
"with",
"the",
"given",
"pattern",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/security/authentication/X509CertificateAuthenticationProvider.java#L72-L88 |
15,774 | yidongnan/grpc-spring-boot-starter | grpc-common-spring-boot/src/main/java/net/devh/boot/grpc/common/util/GrpcUtils.java | GrpcUtils.extractMethodName | public static String extractMethodName(final MethodDescriptor<?, ?> method) {
// This method is the equivalent of MethodDescriptor.extractFullServiceName
final String fullMethodName = method.getFullMethodName();
final int index = fullMethodName.lastIndexOf('/');
if (index == -1) {
... | java | public static String extractMethodName(final MethodDescriptor<?, ?> method) {
// This method is the equivalent of MethodDescriptor.extractFullServiceName
final String fullMethodName = method.getFullMethodName();
final int index = fullMethodName.lastIndexOf('/');
if (index == -1) {
... | [
"public",
"static",
"String",
"extractMethodName",
"(",
"final",
"MethodDescriptor",
"<",
"?",
",",
"?",
">",
"method",
")",
"{",
"// This method is the equivalent of MethodDescriptor.extractFullServiceName",
"final",
"String",
"fullMethodName",
"=",
"method",
".",
"getFu... | Extracts the method name from the given method.
@param method The method to get the method name from.
@return The extracted method name.
@see #extractServiceName(MethodDescriptor) | [
"Extracts",
"the",
"method",
"name",
"from",
"the",
"given",
"method",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-common-spring-boot/src/main/java/net/devh/boot/grpc/common/util/GrpcUtils.java#L48-L56 |
15,775 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/autoconfigure/GrpcServerMetricAutoConfiguration.java | GrpcServerMetricAutoConfiguration.collectMethodNamesForService | protected List<String> collectMethodNamesForService(final ServiceDescriptor serviceDescriptor) {
final List<String> methods = new ArrayList<>();
for (final MethodDescriptor<?, ?> grpcMethod : serviceDescriptor.getMethods()) {
methods.add(extractMethodName(grpcMethod));
}
meth... | java | protected List<String> collectMethodNamesForService(final ServiceDescriptor serviceDescriptor) {
final List<String> methods = new ArrayList<>();
for (final MethodDescriptor<?, ?> grpcMethod : serviceDescriptor.getMethods()) {
methods.add(extractMethodName(grpcMethod));
}
meth... | [
"protected",
"List",
"<",
"String",
">",
"collectMethodNamesForService",
"(",
"final",
"ServiceDescriptor",
"serviceDescriptor",
")",
"{",
"final",
"List",
"<",
"String",
">",
"methods",
"=",
"new",
"ArrayList",
"<>",
"(",
")",
";",
"for",
"(",
"final",
"Metho... | Gets all method names from the given service descriptor.
@param serviceDescriptor The service descriptor to get the names from.
@return The newly created and sorted list of the method names. | [
"Gets",
"all",
"method",
"names",
"from",
"the",
"given",
"service",
"descriptor",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/autoconfigure/GrpcServerMetricAutoConfiguration.java#L108-L115 |
15,776 | yidongnan/grpc-spring-boot-starter | grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/autoconfigure/GrpcClientAutoConfiguration.java | GrpcClientAutoConfiguration.grpcLoadBalancerConfigurer | @ConditionalOnSingleCandidate(LoadBalancer.Factory.class)
@ConditionalOnMissingBean(name = "grpcLoadBalancerConfigurer")
@Bean
@SuppressWarnings("deprecation")
@Deprecated
public GrpcChannelConfigurer grpcLoadBalancerConfigurer(final LoadBalancer.Factory loadBalancerFactory) {
return (channe... | java | @ConditionalOnSingleCandidate(LoadBalancer.Factory.class)
@ConditionalOnMissingBean(name = "grpcLoadBalancerConfigurer")
@Bean
@SuppressWarnings("deprecation")
@Deprecated
public GrpcChannelConfigurer grpcLoadBalancerConfigurer(final LoadBalancer.Factory loadBalancerFactory) {
return (channe... | [
"@",
"ConditionalOnSingleCandidate",
"(",
"LoadBalancer",
".",
"Factory",
".",
"class",
")",
"@",
"ConditionalOnMissingBean",
"(",
"name",
"=",
"\"grpcLoadBalancerConfigurer\"",
")",
"@",
"Bean",
"@",
"SuppressWarnings",
"(",
"\"deprecation\"",
")",
"@",
"Deprecated",... | Creates the load balancer configurer bean for the given load balancer factory.
@param loadBalancerFactory The factory that should be used for all
@return The load balancer factory bean.
@see ManagedChannelBuilder#loadBalancerFactory(io.grpc.LoadBalancer.Factory)
@deprecated This method disables service-config-based ... | [
"Creates",
"the",
"load",
"balancer",
"configurer",
"bean",
"for",
"the",
"given",
"load",
"balancer",
"factory",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/autoconfigure/GrpcClientAutoConfiguration.java#L101-L108 |
15,777 | yidongnan/grpc-spring-boot-starter | grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/autoconfigure/GrpcClientAutoConfiguration.java | GrpcClientAutoConfiguration.nettyGrpcChannelFactory | @ConditionalOnMissingBean(GrpcChannelFactory.class)
@ConditionalOnClass(name = {"io.netty.channel.Channel", "io.grpc.netty.NettyChannelBuilder"})
@Bean
public GrpcChannelFactory nettyGrpcChannelFactory(final GrpcChannelsProperties properties,
final NameResolver.Factory nameResolverFactory,
... | java | @ConditionalOnMissingBean(GrpcChannelFactory.class)
@ConditionalOnClass(name = {"io.netty.channel.Channel", "io.grpc.netty.NettyChannelBuilder"})
@Bean
public GrpcChannelFactory nettyGrpcChannelFactory(final GrpcChannelsProperties properties,
final NameResolver.Factory nameResolverFactory,
... | [
"@",
"ConditionalOnMissingBean",
"(",
"GrpcChannelFactory",
".",
"class",
")",
"@",
"ConditionalOnClass",
"(",
"name",
"=",
"{",
"\"io.netty.channel.Channel\"",
",",
"\"io.grpc.netty.NettyChannelBuilder\"",
"}",
")",
"@",
"Bean",
"public",
"GrpcChannelFactory",
"nettyGrpc... | Then try the normal netty channel factory | [
"Then",
"try",
"the",
"normal",
"netty",
"channel",
"factory"
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/autoconfigure/GrpcClientAutoConfiguration.java#L171-L184 |
15,778 | yidongnan/grpc-spring-boot-starter | grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/autoconfigure/GrpcClientAutoConfiguration.java | GrpcClientAutoConfiguration.inProcessGrpcChannelFactory | @ConditionalOnMissingBean(GrpcChannelFactory.class)
@Bean
public GrpcChannelFactory inProcessGrpcChannelFactory(final GrpcChannelsProperties properties,
final GlobalClientInterceptorRegistry globalClientInterceptorRegistry,
final List<GrpcChannelConfigurer> channelConfigurers) {
... | java | @ConditionalOnMissingBean(GrpcChannelFactory.class)
@Bean
public GrpcChannelFactory inProcessGrpcChannelFactory(final GrpcChannelsProperties properties,
final GlobalClientInterceptorRegistry globalClientInterceptorRegistry,
final List<GrpcChannelConfigurer> channelConfigurers) {
... | [
"@",
"ConditionalOnMissingBean",
"(",
"GrpcChannelFactory",
".",
"class",
")",
"@",
"Bean",
"public",
"GrpcChannelFactory",
"inProcessGrpcChannelFactory",
"(",
"final",
"GrpcChannelsProperties",
"properties",
",",
"final",
"GlobalClientInterceptorRegistry",
"globalClientInterce... | Finally try the in process channel factory | [
"Finally",
"try",
"the",
"in",
"process",
"channel",
"factory"
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/autoconfigure/GrpcClientAutoConfiguration.java#L187-L193 |
15,779 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/autoconfigure/GrpcServerFactoryAutoConfiguration.java | GrpcServerFactoryAutoConfiguration.shadedNettyGrpcServerFactory | @ConditionalOnClass(name = {"io.grpc.netty.shaded.io.netty.channel.Channel",
"io.grpc.netty.shaded.io.grpc.netty.NettyServerBuilder"})
@Bean
public ShadedNettyGrpcServerFactory shadedNettyGrpcServerFactory(final GrpcServerProperties properties,
final GrpcServiceDiscoverer serviceDiscover... | java | @ConditionalOnClass(name = {"io.grpc.netty.shaded.io.netty.channel.Channel",
"io.grpc.netty.shaded.io.grpc.netty.NettyServerBuilder"})
@Bean
public ShadedNettyGrpcServerFactory shadedNettyGrpcServerFactory(final GrpcServerProperties properties,
final GrpcServiceDiscoverer serviceDiscover... | [
"@",
"ConditionalOnClass",
"(",
"name",
"=",
"{",
"\"io.grpc.netty.shaded.io.netty.channel.Channel\"",
",",
"\"io.grpc.netty.shaded.io.grpc.netty.NettyServerBuilder\"",
"}",
")",
"@",
"Bean",
"public",
"ShadedNettyGrpcServerFactory",
"shadedNettyGrpcServerFactory",
"(",
"final",
... | Creates a GrpcServerFactory using the shaded netty. This is the recommended default for gRPC.
@param properties The properties used to configure the server.
@param serviceDiscoverer The discoverer used to identify the services that should be served.
@param serverConfigurers The server configurers that contain addition... | [
"Creates",
"a",
"GrpcServerFactory",
"using",
"the",
"shaded",
"netty",
".",
"This",
"is",
"the",
"recommended",
"default",
"for",
"gRPC",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/autoconfigure/GrpcServerFactoryAutoConfiguration.java#L60-L70 |
15,780 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/autoconfigure/GrpcServerFactoryAutoConfiguration.java | GrpcServerFactoryAutoConfiguration.nettyGrpcServerFactory | @ConditionalOnMissingBean
@ConditionalOnClass(name = {"io.netty.channel.Channel", "io.grpc.netty.NettyServerBuilder"})
@Bean
public NettyGrpcServerFactory nettyGrpcServerFactory(final GrpcServerProperties properties,
final GrpcServiceDiscoverer serviceDiscoverer, final List<GrpcServerConfigurer>... | java | @ConditionalOnMissingBean
@ConditionalOnClass(name = {"io.netty.channel.Channel", "io.grpc.netty.NettyServerBuilder"})
@Bean
public NettyGrpcServerFactory nettyGrpcServerFactory(final GrpcServerProperties properties,
final GrpcServiceDiscoverer serviceDiscoverer, final List<GrpcServerConfigurer>... | [
"@",
"ConditionalOnMissingBean",
"@",
"ConditionalOnClass",
"(",
"name",
"=",
"{",
"\"io.netty.channel.Channel\"",
",",
"\"io.grpc.netty.NettyServerBuilder\"",
"}",
")",
"@",
"Bean",
"public",
"NettyGrpcServerFactory",
"nettyGrpcServerFactory",
"(",
"final",
"GrpcServerProper... | Creates a GrpcServerFactory using the non-shaded netty. This is the fallback, if the shaded one is not present.
@param properties The properties used to configure the server.
@param serviceDiscoverer The discoverer used to identify the services that should be served.
@param serverConfigurers The server configurers tha... | [
"Creates",
"a",
"GrpcServerFactory",
"using",
"the",
"non",
"-",
"shaded",
"netty",
".",
"This",
"is",
"the",
"fallback",
"if",
"the",
"shaded",
"one",
"is",
"not",
"present",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/autoconfigure/GrpcServerFactoryAutoConfiguration.java#L94-L104 |
15,781 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/autoconfigure/GrpcServerFactoryAutoConfiguration.java | GrpcServerFactoryAutoConfiguration.nettyGrpcServerLifecycle | @ConditionalOnMissingBean
@ConditionalOnClass(name = {"io.netty.channel.Channel", "io.grpc.netty.NettyServerBuilder"})
@Bean
public GrpcServerLifecycle nettyGrpcServerLifecycle(final NettyGrpcServerFactory factory) {
return new GrpcServerLifecycle(factory);
} | java | @ConditionalOnMissingBean
@ConditionalOnClass(name = {"io.netty.channel.Channel", "io.grpc.netty.NettyServerBuilder"})
@Bean
public GrpcServerLifecycle nettyGrpcServerLifecycle(final NettyGrpcServerFactory factory) {
return new GrpcServerLifecycle(factory);
} | [
"@",
"ConditionalOnMissingBean",
"@",
"ConditionalOnClass",
"(",
"name",
"=",
"{",
"\"io.netty.channel.Channel\"",
",",
"\"io.grpc.netty.NettyServerBuilder\"",
"}",
")",
"@",
"Bean",
"public",
"GrpcServerLifecycle",
"nettyGrpcServerLifecycle",
"(",
"final",
"NettyGrpcServerFa... | The server lifecycle bean for netty based server.
@param factory The factory used to create the lifecycle.
@return The inter-process server lifecycle bean. | [
"The",
"server",
"lifecycle",
"bean",
"for",
"netty",
"based",
"server",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/autoconfigure/GrpcServerFactoryAutoConfiguration.java#L112-L117 |
15,782 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/autoconfigure/GrpcServerFactoryAutoConfiguration.java | GrpcServerFactoryAutoConfiguration.inProcessGrpcServerFactory | @ConditionalOnProperty(prefix = "grpc.server", name = "inProcessName")
@Bean
public InProcessGrpcServerFactory inProcessGrpcServerFactory(final GrpcServerProperties properties,
final GrpcServiceDiscoverer serviceDiscoverer) {
final InProcessGrpcServerFactory factory = new InProcessGrpcServer... | java | @ConditionalOnProperty(prefix = "grpc.server", name = "inProcessName")
@Bean
public InProcessGrpcServerFactory inProcessGrpcServerFactory(final GrpcServerProperties properties,
final GrpcServiceDiscoverer serviceDiscoverer) {
final InProcessGrpcServerFactory factory = new InProcessGrpcServer... | [
"@",
"ConditionalOnProperty",
"(",
"prefix",
"=",
"\"grpc.server\"",
",",
"name",
"=",
"\"inProcessName\"",
")",
"@",
"Bean",
"public",
"InProcessGrpcServerFactory",
"inProcessGrpcServerFactory",
"(",
"final",
"GrpcServerProperties",
"properties",
",",
"final",
"GrpcServi... | Creates a GrpcServerFactory using the in-process-server, if a name is specified.
@param properties The properties used to configure the server.
@param serviceDiscoverer The discoverer used to identify the services that should be served.
@return The shadedNettyGrpcServerFactory bean. | [
"Creates",
"a",
"GrpcServerFactory",
"using",
"the",
"in",
"-",
"process",
"-",
"server",
"if",
"a",
"name",
"is",
"specified",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/autoconfigure/GrpcServerFactoryAutoConfiguration.java#L126-L135 |
15,783 | yidongnan/grpc-spring-boot-starter | grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/config/GrpcChannelsProperties.java | GrpcChannelsProperties.getChannel | public GrpcChannelProperties getChannel(final String name) {
final GrpcChannelProperties properties = getRawChannel(name);
properties.copyDefaultsFrom(getGlobalChannel());
return properties;
} | java | public GrpcChannelProperties getChannel(final String name) {
final GrpcChannelProperties properties = getRawChannel(name);
properties.copyDefaultsFrom(getGlobalChannel());
return properties;
} | [
"public",
"GrpcChannelProperties",
"getChannel",
"(",
"final",
"String",
"name",
")",
"{",
"final",
"GrpcChannelProperties",
"properties",
"=",
"getRawChannel",
"(",
"name",
")",
";",
"properties",
".",
"copyDefaultsFrom",
"(",
"getGlobalChannel",
"(",
")",
")",
"... | Gets the properties for the given channel. If the properties for the specified channel name do not yet exist,
they are created automatically. Before the instance is returned, the unset values are filled with values from the
global properties.
@param name The name of the channel to get the properties for.
@return The p... | [
"Gets",
"the",
"properties",
"for",
"the",
"given",
"channel",
".",
"If",
"the",
"properties",
"for",
"the",
"specified",
"channel",
"name",
"do",
"not",
"yet",
"exist",
"they",
"are",
"created",
"automatically",
".",
"Before",
"the",
"instance",
"is",
"retu... | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/config/GrpcChannelsProperties.java#L67-L71 |
15,784 | yidongnan/grpc-spring-boot-starter | grpc-common-spring-boot/src/main/java/net/devh/boot/grpc/common/metric/AbstractMetricCollectingInterceptor.java | AbstractMetricCollectingInterceptor.asTimerFunction | protected Function<Code, Timer> asTimerFunction(final Supplier<Timer.Builder> timerTemplate) {
final Map<Code, Timer> cache = new EnumMap<>(Code.class);
final Function<Code, Timer> creator = code -> timerTemplate.get()
.tag(TAG_STATUS_CODE, code.name())
.register(this.reg... | java | protected Function<Code, Timer> asTimerFunction(final Supplier<Timer.Builder> timerTemplate) {
final Map<Code, Timer> cache = new EnumMap<>(Code.class);
final Function<Code, Timer> creator = code -> timerTemplate.get()
.tag(TAG_STATUS_CODE, code.name())
.register(this.reg... | [
"protected",
"Function",
"<",
"Code",
",",
"Timer",
">",
"asTimerFunction",
"(",
"final",
"Supplier",
"<",
"Timer",
".",
"Builder",
">",
"timerTemplate",
")",
"{",
"final",
"Map",
"<",
"Code",
",",
"Timer",
">",
"cache",
"=",
"new",
"EnumMap",
"<>",
"(",... | Creates a new timer function using the given template. This method initializes the default timers.
@param timerTemplate The template to create the instances from.
@return The newly created function that returns a timer for a given code. | [
"Creates",
"a",
"new",
"timer",
"function",
"using",
"the",
"given",
"template",
".",
"This",
"method",
"initializes",
"the",
"default",
"timers",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-common-spring-boot/src/main/java/net/devh/boot/grpc/common/metric/AbstractMetricCollectingInterceptor.java#L150-L161 |
15,785 | yidongnan/grpc-spring-boot-starter | grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/config/GrpcChannelProperties.java | GrpcChannelProperties.copyDefaultsFrom | public void copyDefaultsFrom(final GrpcChannelProperties config) {
if (this == config) {
return;
}
if (this.address == null) {
this.address = config.address;
}
if (this.defaultLoadBalancingPolicy == null) {
this.defaultLoadBalancingPolicy = con... | java | public void copyDefaultsFrom(final GrpcChannelProperties config) {
if (this == config) {
return;
}
if (this.address == null) {
this.address = config.address;
}
if (this.defaultLoadBalancingPolicy == null) {
this.defaultLoadBalancingPolicy = con... | [
"public",
"void",
"copyDefaultsFrom",
"(",
"final",
"GrpcChannelProperties",
"config",
")",
"{",
"if",
"(",
"this",
"==",
"config",
")",
"{",
"return",
";",
"}",
"if",
"(",
"this",
".",
"address",
"==",
"null",
")",
"{",
"this",
".",
"address",
"=",
"c... | Copies the defaults from the given configuration. Values are considered "default" if they are null. Please note
that the getters might return fallback values instead.
@param config The config to copy the defaults from. | [
"Copies",
"the",
"defaults",
"from",
"the",
"given",
"configuration",
".",
"Values",
"are",
"considered",
"default",
"if",
"they",
"are",
"null",
".",
"Please",
"note",
"that",
"the",
"getters",
"might",
"return",
"fallback",
"values",
"instead",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/config/GrpcChannelProperties.java#L380-L412 |
15,786 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/security/check/ManualGrpcSecurityMetadataSource.java | ManualGrpcSecurityMetadataSource.set | public ManualGrpcSecurityMetadataSource set(final ServiceDescriptor service, final AccessPredicate predicate) {
requireNonNull(service, "service");
final Collection<ConfigAttribute> wrappedPredicate = wrap(predicate);
for (final MethodDescriptor<?, ?> method : service.getMethods()) {
... | java | public ManualGrpcSecurityMetadataSource set(final ServiceDescriptor service, final AccessPredicate predicate) {
requireNonNull(service, "service");
final Collection<ConfigAttribute> wrappedPredicate = wrap(predicate);
for (final MethodDescriptor<?, ?> method : service.getMethods()) {
... | [
"public",
"ManualGrpcSecurityMetadataSource",
"set",
"(",
"final",
"ServiceDescriptor",
"service",
",",
"final",
"AccessPredicate",
"predicate",
")",
"{",
"requireNonNull",
"(",
"service",
",",
"\"service\"",
")",
";",
"final",
"Collection",
"<",
"ConfigAttribute",
">... | Set the given access predicate for the all methods of the given service. This will replace previously set
predicates.
@param service The service to protect with a custom check.
@param predicate The predicate used to check the {@link Authentication}.
@return This instance for chaining.
@see #setDefault(AccessPredicate) | [
"Set",
"the",
"given",
"access",
"predicate",
"for",
"the",
"all",
"methods",
"of",
"the",
"given",
"service",
".",
"This",
"will",
"replace",
"previously",
"set",
"predicates",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/security/check/ManualGrpcSecurityMetadataSource.java#L70-L77 |
15,787 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/security/check/ManualGrpcSecurityMetadataSource.java | ManualGrpcSecurityMetadataSource.remove | public ManualGrpcSecurityMetadataSource remove(final ServiceDescriptor service) {
requireNonNull(service, "service");
for (final MethodDescriptor<?, ?> method : service.getMethods()) {
this.accessMap.remove(method);
}
return this;
} | java | public ManualGrpcSecurityMetadataSource remove(final ServiceDescriptor service) {
requireNonNull(service, "service");
for (final MethodDescriptor<?, ?> method : service.getMethods()) {
this.accessMap.remove(method);
}
return this;
} | [
"public",
"ManualGrpcSecurityMetadataSource",
"remove",
"(",
"final",
"ServiceDescriptor",
"service",
")",
"{",
"requireNonNull",
"(",
"service",
",",
"\"service\"",
")",
";",
"for",
"(",
"final",
"MethodDescriptor",
"<",
"?",
",",
"?",
">",
"method",
":",
"serv... | Removes all access predicates for the all methods of the given service. After that, the default will be used for
those methods.
@param service The service to protect with only the default.
@return This instance for chaining.
@see #setDefault(AccessPredicate) | [
"Removes",
"all",
"access",
"predicates",
"for",
"the",
"all",
"methods",
"of",
"the",
"given",
"service",
".",
"After",
"that",
"the",
"default",
"will",
"be",
"used",
"for",
"those",
"methods",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/security/check/ManualGrpcSecurityMetadataSource.java#L87-L93 |
15,788 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/security/check/ManualGrpcSecurityMetadataSource.java | ManualGrpcSecurityMetadataSource.set | public ManualGrpcSecurityMetadataSource set(final MethodDescriptor<?, ?> method, final AccessPredicate predicate) {
requireNonNull(method, "method");
this.accessMap.put(method, wrap(predicate));
return this;
} | java | public ManualGrpcSecurityMetadataSource set(final MethodDescriptor<?, ?> method, final AccessPredicate predicate) {
requireNonNull(method, "method");
this.accessMap.put(method, wrap(predicate));
return this;
} | [
"public",
"ManualGrpcSecurityMetadataSource",
"set",
"(",
"final",
"MethodDescriptor",
"<",
"?",
",",
"?",
">",
"method",
",",
"final",
"AccessPredicate",
"predicate",
")",
"{",
"requireNonNull",
"(",
"method",
",",
"\"method\"",
")",
";",
"this",
".",
"accessMa... | Set the given access predicate for the given method. This will replace previously set predicates.
@param method The method to protect with a custom check.
@param predicate The predicate used to check the {@link Authentication}.
@return This instance for chaining.
@see #setDefault(AccessPredicate) | [
"Set",
"the",
"given",
"access",
"predicate",
"for",
"the",
"given",
"method",
".",
"This",
"will",
"replace",
"previously",
"set",
"predicates",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/security/check/ManualGrpcSecurityMetadataSource.java#L103-L107 |
15,789 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/security/check/ManualGrpcSecurityMetadataSource.java | ManualGrpcSecurityMetadataSource.wrap | private Collection<ConfigAttribute> wrap(final AccessPredicate predicate) {
requireNonNull(predicate, "predicate");
if (predicate == AccessPredicates.PERMIT_ALL) {
return of(); // Empty collection => public invocation
}
return of(new AccessPredicateConfigAttribute(predicate))... | java | private Collection<ConfigAttribute> wrap(final AccessPredicate predicate) {
requireNonNull(predicate, "predicate");
if (predicate == AccessPredicates.PERMIT_ALL) {
return of(); // Empty collection => public invocation
}
return of(new AccessPredicateConfigAttribute(predicate))... | [
"private",
"Collection",
"<",
"ConfigAttribute",
">",
"wrap",
"(",
"final",
"AccessPredicate",
"predicate",
")",
"{",
"requireNonNull",
"(",
"predicate",
",",
"\"predicate\"",
")",
";",
"if",
"(",
"predicate",
"==",
"AccessPredicates",
".",
"PERMIT_ALL",
")",
"{... | Wraps the given predicate in a configuration attribute and an immutable collection.
@param predicate The predicate to wrap.
@return The newly created list with the given predicate. | [
"Wraps",
"the",
"given",
"predicate",
"in",
"a",
"configuration",
"attribute",
"and",
"an",
"immutable",
"collection",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/security/check/ManualGrpcSecurityMetadataSource.java#L139-L145 |
15,790 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/serverfactory/AbstractGrpcServerFactory.java | AbstractGrpcServerFactory.configureServices | protected void configureServices(final T builder) {
// support health check
if (this.properties.isHealthServiceEnabled()) {
builder.addService(this.healthStatusManager.getHealthService());
}
if (this.properties.isReflectionServiceEnabled()) {
builder.addService(Pr... | java | protected void configureServices(final T builder) {
// support health check
if (this.properties.isHealthServiceEnabled()) {
builder.addService(this.healthStatusManager.getHealthService());
}
if (this.properties.isReflectionServiceEnabled()) {
builder.addService(Pr... | [
"protected",
"void",
"configureServices",
"(",
"final",
"T",
"builder",
")",
"{",
"// support health check",
"if",
"(",
"this",
".",
"properties",
".",
"isHealthServiceEnabled",
"(",
")",
")",
"{",
"builder",
".",
"addService",
"(",
"this",
".",
"healthStatusMan... | Configures the services that should be served by the server.
@param builder The server builder to configure. | [
"Configures",
"the",
"services",
"that",
"should",
"be",
"served",
"by",
"the",
"server",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/serverfactory/AbstractGrpcServerFactory.java#L104-L120 |
15,791 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/serverfactory/AbstractGrpcServerFactory.java | AbstractGrpcServerFactory.configureLimits | protected void configureLimits(final T builder) {
final Integer maxInboundMessageSize = this.properties.getMaxInboundMessageSize();
if (maxInboundMessageSize != null) {
builder.maxInboundMessageSize(maxInboundMessageSize);
}
} | java | protected void configureLimits(final T builder) {
final Integer maxInboundMessageSize = this.properties.getMaxInboundMessageSize();
if (maxInboundMessageSize != null) {
builder.maxInboundMessageSize(maxInboundMessageSize);
}
} | [
"protected",
"void",
"configureLimits",
"(",
"final",
"T",
"builder",
")",
"{",
"final",
"Integer",
"maxInboundMessageSize",
"=",
"this",
".",
"properties",
".",
"getMaxInboundMessageSize",
"(",
")",
";",
"if",
"(",
"maxInboundMessageSize",
"!=",
"null",
")",
"{... | Configures limits such as max message sizes that should be used by the server.
@param builder The server builder to configure. | [
"Configures",
"limits",
"such",
"as",
"max",
"message",
"sizes",
"that",
"should",
"be",
"used",
"by",
"the",
"server",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/serverfactory/AbstractGrpcServerFactory.java#L172-L177 |
15,792 | yidongnan/grpc-spring-boot-starter | grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/channelfactory/AbstractChannelFactory.java | AbstractChannelFactory.configure | protected void configure(final T builder, final String name) {
configureKeepAlive(builder, name);
configureSecurity(builder, name);
configureLimits(builder, name);
configureCompression(builder, name);
for (final GrpcChannelConfigurer channelConfigurer : this.channelConfigurers) {... | java | protected void configure(final T builder, final String name) {
configureKeepAlive(builder, name);
configureSecurity(builder, name);
configureLimits(builder, name);
configureCompression(builder, name);
for (final GrpcChannelConfigurer channelConfigurer : this.channelConfigurers) {... | [
"protected",
"void",
"configure",
"(",
"final",
"T",
"builder",
",",
"final",
"String",
"name",
")",
"{",
"configureKeepAlive",
"(",
"builder",
",",
"name",
")",
";",
"configureSecurity",
"(",
"builder",
",",
"name",
")",
";",
"configureLimits",
"(",
"builde... | Configures the given channel builder. This method can be overwritten to add features that are not yet supported
by this library.
@param builder The channel builder to configure.
@param name The name of the client to configure. | [
"Configures",
"the",
"given",
"channel",
"builder",
".",
"This",
"method",
"can",
"be",
"overwritten",
"to",
"add",
"features",
"that",
"are",
"not",
"yet",
"supported",
"by",
"this",
"library",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/channelfactory/AbstractChannelFactory.java#L152-L160 |
15,793 | yidongnan/grpc-spring-boot-starter | grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/channelfactory/AbstractChannelFactory.java | AbstractChannelFactory.configureKeepAlive | protected void configureKeepAlive(final T builder, final String name) {
final GrpcChannelProperties properties = getPropertiesFor(name);
if (properties.isEnableKeepAlive()) {
builder.keepAliveTime(properties.getKeepAliveTime().toNanos(), TimeUnit.NANOSECONDS)
.keepAliveTi... | java | protected void configureKeepAlive(final T builder, final String name) {
final GrpcChannelProperties properties = getPropertiesFor(name);
if (properties.isEnableKeepAlive()) {
builder.keepAliveTime(properties.getKeepAliveTime().toNanos(), TimeUnit.NANOSECONDS)
.keepAliveTi... | [
"protected",
"void",
"configureKeepAlive",
"(",
"final",
"T",
"builder",
",",
"final",
"String",
"name",
")",
"{",
"final",
"GrpcChannelProperties",
"properties",
"=",
"getPropertiesFor",
"(",
"name",
")",
";",
"if",
"(",
"properties",
".",
"isEnableKeepAlive",
... | Configures the keep alive options that should be used by the channel.
@param builder The channel builder to configure.
@param name The name of the client to configure. | [
"Configures",
"the",
"keep",
"alive",
"options",
"that",
"should",
"be",
"used",
"by",
"the",
"channel",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/channelfactory/AbstractChannelFactory.java#L168-L175 |
15,794 | yidongnan/grpc-spring-boot-starter | grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/channelfactory/AbstractChannelFactory.java | AbstractChannelFactory.configureSecurity | protected void configureSecurity(final T builder, final String name) {
final GrpcChannelProperties properties = getPropertiesFor(name);
final Security security = properties.getSecurity();
if (properties.getNegotiationType() != NegotiationType.TLS // non-default
|| isNonNullAndNo... | java | protected void configureSecurity(final T builder, final String name) {
final GrpcChannelProperties properties = getPropertiesFor(name);
final Security security = properties.getSecurity();
if (properties.getNegotiationType() != NegotiationType.TLS // non-default
|| isNonNullAndNo... | [
"protected",
"void",
"configureSecurity",
"(",
"final",
"T",
"builder",
",",
"final",
"String",
"name",
")",
"{",
"final",
"GrpcChannelProperties",
"properties",
"=",
"getPropertiesFor",
"(",
"name",
")",
";",
"final",
"Security",
"security",
"=",
"properties",
... | Configures the security options that should be used by the channel.
@param builder The channel builder to configure.
@param name The name of the client to configure. | [
"Configures",
"the",
"security",
"options",
"that",
"should",
"be",
"used",
"by",
"the",
"channel",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/channelfactory/AbstractChannelFactory.java#L183-L195 |
15,795 | yidongnan/grpc-spring-boot-starter | grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/channelfactory/AbstractChannelFactory.java | AbstractChannelFactory.configureLimits | protected void configureLimits(final T builder, final String name) {
final GrpcChannelProperties properties = getPropertiesFor(name);
final Integer maxInboundMessageSize = properties.getMaxInboundMessageSize();
if (maxInboundMessageSize != null) {
builder.maxInboundMessageSize(maxInb... | java | protected void configureLimits(final T builder, final String name) {
final GrpcChannelProperties properties = getPropertiesFor(name);
final Integer maxInboundMessageSize = properties.getMaxInboundMessageSize();
if (maxInboundMessageSize != null) {
builder.maxInboundMessageSize(maxInb... | [
"protected",
"void",
"configureLimits",
"(",
"final",
"T",
"builder",
",",
"final",
"String",
"name",
")",
"{",
"final",
"GrpcChannelProperties",
"properties",
"=",
"getPropertiesFor",
"(",
"name",
")",
";",
"final",
"Integer",
"maxInboundMessageSize",
"=",
"prope... | Configures limits such as max message sizes that should be used by the channel.
@param builder The channel builder to configure.
@param name The name of the client to configure. | [
"Configures",
"limits",
"such",
"as",
"max",
"message",
"sizes",
"that",
"should",
"be",
"used",
"by",
"the",
"channel",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/channelfactory/AbstractChannelFactory.java#L230-L236 |
15,796 | yidongnan/grpc-spring-boot-starter | grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/channelfactory/AbstractChannelFactory.java | AbstractChannelFactory.configureCompression | protected void configureCompression(final T builder, final String name) {
final GrpcChannelProperties properties = getPropertiesFor(name);
if (properties.isFullStreamDecompression()) {
builder.enableFullStreamDecompression();
}
} | java | protected void configureCompression(final T builder, final String name) {
final GrpcChannelProperties properties = getPropertiesFor(name);
if (properties.isFullStreamDecompression()) {
builder.enableFullStreamDecompression();
}
} | [
"protected",
"void",
"configureCompression",
"(",
"final",
"T",
"builder",
",",
"final",
"String",
"name",
")",
"{",
"final",
"GrpcChannelProperties",
"properties",
"=",
"getPropertiesFor",
"(",
"name",
")",
";",
"if",
"(",
"properties",
".",
"isFullStreamDecompre... | Configures the compression options that should be used by the channel.
@param builder The channel builder to configure.
@param name The name of the client to configure. | [
"Configures",
"the",
"compression",
"options",
"that",
"should",
"be",
"used",
"by",
"the",
"channel",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/channelfactory/AbstractChannelFactory.java#L244-L249 |
15,797 | yidongnan/grpc-spring-boot-starter | grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/channelfactory/AbstractChannelFactory.java | AbstractChannelFactory.close | @Override
@PreDestroy
public synchronized void close() {
if (this.shutdown) {
return;
}
this.shutdown = true;
for (final ManagedChannel channel : this.channels.values()) {
channel.shutdown();
}
try {
final long waitLimit = Syste... | java | @Override
@PreDestroy
public synchronized void close() {
if (this.shutdown) {
return;
}
this.shutdown = true;
for (final ManagedChannel channel : this.channels.values()) {
channel.shutdown();
}
try {
final long waitLimit = Syste... | [
"@",
"Override",
"@",
"PreDestroy",
"public",
"synchronized",
"void",
"close",
"(",
")",
"{",
"if",
"(",
"this",
".",
"shutdown",
")",
"{",
"return",
";",
"}",
"this",
".",
"shutdown",
"=",
"true",
";",
"for",
"(",
"final",
"ManagedChannel",
"channel",
... | Closes this channel factory and the channels created by this instance. The shutdown happens in two phases, first
an orderly shutdown is initiated on all channels and then the method waits for all channels to terminate. If the
channels don't have terminated after 60 seconds then they will be forcefully shutdown. | [
"Closes",
"this",
"channel",
"factory",
"and",
"the",
"channels",
"created",
"by",
"this",
"instance",
".",
"The",
"shutdown",
"happens",
"in",
"two",
"phases",
"first",
"an",
"orderly",
"shutdown",
"is",
"initiated",
"on",
"all",
"channels",
"and",
"then",
... | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-client-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/client/channelfactory/AbstractChannelFactory.java#L256-L288 |
15,798 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/serverfactory/GrpcServerLifecycle.java | GrpcServerLifecycle.createAndStartGrpcServer | protected void createAndStartGrpcServer() throws IOException {
final Server localServer = this.server;
if (localServer == null) {
this.server = this.factory.createServer();
this.server.start();
log.info("gRPC Server started, listening on address: " + this.factory.getA... | java | protected void createAndStartGrpcServer() throws IOException {
final Server localServer = this.server;
if (localServer == null) {
this.server = this.factory.createServer();
this.server.start();
log.info("gRPC Server started, listening on address: " + this.factory.getA... | [
"protected",
"void",
"createAndStartGrpcServer",
"(",
")",
"throws",
"IOException",
"{",
"final",
"Server",
"localServer",
"=",
"this",
".",
"server",
";",
"if",
"(",
"localServer",
"==",
"null",
")",
"{",
"this",
".",
"server",
"=",
"this",
".",
"factory",
... | Creates and starts the grpc server.
@throws IOException If the server is unable to bind the port. | [
"Creates",
"and",
"starts",
"the",
"grpc",
"server",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/serverfactory/GrpcServerLifecycle.java#L86-L109 |
15,799 | yidongnan/grpc-spring-boot-starter | grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/serverfactory/GrpcServerLifecycle.java | GrpcServerLifecycle.stopAndReleaseGrpcServer | protected void stopAndReleaseGrpcServer() {
factory.destroy();
Server localServer = this.server;
if (localServer != null) {
localServer.shutdown();
this.server = null;
log.info("gRPC server shutdown.");
}
} | java | protected void stopAndReleaseGrpcServer() {
factory.destroy();
Server localServer = this.server;
if (localServer != null) {
localServer.shutdown();
this.server = null;
log.info("gRPC server shutdown.");
}
} | [
"protected",
"void",
"stopAndReleaseGrpcServer",
"(",
")",
"{",
"factory",
".",
"destroy",
"(",
")",
";",
"Server",
"localServer",
"=",
"this",
".",
"server",
";",
"if",
"(",
"localServer",
"!=",
"null",
")",
"{",
"localServer",
".",
"shutdown",
"(",
")",
... | Initiates an orderly shutdown of the grpc server and releases the references to the server. This call does not
wait for the server to be completely shut down. | [
"Initiates",
"an",
"orderly",
"shutdown",
"of",
"the",
"grpc",
"server",
"and",
"releases",
"the",
"references",
"to",
"the",
"server",
".",
"This",
"call",
"does",
"not",
"wait",
"for",
"the",
"server",
"to",
"be",
"completely",
"shut",
"down",
"."
] | 07f8853cfafc9707584f2371aff012e590217b85 | https://github.com/yidongnan/grpc-spring-boot-starter/blob/07f8853cfafc9707584f2371aff012e590217b85/grpc-server-spring-boot-autoconfigure/src/main/java/net/devh/boot/grpc/server/serverfactory/GrpcServerLifecycle.java#L115-L123 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.