code: public Observable<RegistryListCredentialsResultInner> regenerateCredentialAsync(String resourceGroupName, String registryName, PasswordName name) {
          return regenerateCredentialWithServiceResponseAsync(resourceGroupName, registryName, name).map(new Func1<ServiceResponse<RegistryListCredentialsResultInner>, RegistryListCredentialsResultInner>() {
              @Override
              public RegistryListCredentialsResultInner call(ServiceResponse<RegistryListCredentialsResultInner> response) {
                  return response.body();
              }
          });
      }
docs: Regenerates one of the login credentials for the specified container registry.
  
  @param resourceGroupName The name of the resource group to which the container registry belongs.
  @param registryName The name of the container registry.
  @param name Specifies name of the password which should be regenerated -- password or password2. Possible values include: 'password', 'password2'
  @throws IllegalArgumentException thrown if parameters fail the validation
  @return the observable to the RegistryListCredentialsResultInner object