Please note that the contents of this offline web site may be out of date. To access the most recent documentation visit the online version .
Note that links that point to online resources are green in color and will open in a new window.
We would love it if you could give us feedback about this material by filling this form (You have to be online to fill it)



google/appengine/api/users/UserService.php

Table of Contents
Copyright 2007 Google Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

\google\appengine\api\users\UserService

Package: Default

Methods

method public createLoginURL (string $destination_url = null, string $federated_identity = null) : string
static

Computes the login URL for redirection.

Parameters
Name Type Description
$destination_url string

The desired final destination URL for the user once login is complete. If 'destinationURL' does not have a host specified, we will use the host from the current request.

$federated_identity string

The parameter is used to trigger OpenId Login flow, an empty value will trigger Google OpenID Login by default.

Returns
Type Description
string Login URL. If federatedIdentity is set, this will be a federated login using the specified identity. If not, this will use Google Accounts.
Throws
Exception Description
\google\appengine\api\users\UsersException If there was a problem using the Users service.
method public createLogoutURL (string $destination_url) : string
static

Computes the logout URL for this request and specified destination URL, for both federated login App and Google Accounts App.

Parameters
Name Type Description
$destination_url string

The desired final destination URL for the user once logout is complete. If 'destinationURL' does not have a host specified, we will use the host from the current request.

Returns
Type Description
string Logout URL.
Throws
Exception Description
\google\appengine\api\users\UsersException If there was a problem using the Users service.
method public getCurrentUser () : \google\appengine\api\users\User
static

Returns
Type Description
\google\appengine\api\users\User The object representing the current signed in user, or null if no user is signed in.
method public isCurrentUserAdmin () : boolean
static

Return true if the user making this request is an admin for this application, false otherwise.

We specifically make this a separate function, and not a member function of the User class, because admin status is not persisted in the datastore. It only exists for the user making this request right now.

Returns
Type Description
boolean Whether the current user is an administrator of the application.
Documentation was generated by phpDocumentor 2.0.0a12 .