All Downloads are FREE. Search and download functionalities are using the official Maven repository.

dart.auth.oauth.mustache Maven / Gradle / Ivy

There is a newer version: 7.8.0
Show newest version
part of {{pubName}}.api;

class OAuth implements Authentication {
  String accessToken;

  OAuth({this.accessToken}) {
  }

  @override
  void applyToParams(List queryParams, Map headerParams) {
    if (accessToken != null) {
      headerParams["Authorization"] = "Bearer " + accessToken;
    }
  }

  void setAccessToken(String accessToken) {
    this.accessToken = accessToken;
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy