org.alfresco.webdrone.share
Class FactorySharePage

java.lang.Object
  extended by org.alfresco.webdrone.share.FactorySharePage

public final class FactorySharePage
extends Object

Alfresco Share factory, creates the appropriate page object that corresponds to the browser view.

Author:
Michael Suzuki

Field Summary
static String DOCUMENTLIBRARY
           
static String NODE_REFRESH_META_DATA_IDENTIFIER
           
 
Method Summary
static CreateSitePage createSite(WebDrone drone)
          Create site pop up page object.
static UpdateFilePage getFileUpdate(WebDrone drone, String version, boolean editOffLine)
          File upload page pop up object.
static UploadFilePage getFileUpload(WebDrone drone)
          File upload page pop up object.
static SharePage getLibraryPage(WebDrone drone)
          Get a share library page by its type.
static NewFolderPage getNewFolderPage(WebDrone drone)
          New folder page pop up object.
static SharePage getPage(WebDrone drone)
          Creates the appropriate page object based on the current page the WebDrone is on.
static String getPageName(String url)
          Extracts the String value from the last occurrence of slash in the url.
static boolean isDocumentLibraryPage(String pageName)
          Checks if pageName is document library.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DOCUMENTLIBRARY

public static final String DOCUMENTLIBRARY
See Also:
Constant Field Values

NODE_REFRESH_META_DATA_IDENTIFIER

public static final String NODE_REFRESH_META_DATA_IDENTIFIER
See Also:
Constant Field Values
Method Detail

getPage

public static SharePage getPage(WebDrone drone)
                         throws PageException
Creates the appropriate page object based on the current page the WebDrone is on.

Parameters:
drone - WebDrone Alfresco unmanned web browser client
Returns:
SharePage the page object response
Throws:
PageException

getFileUpload

public static UploadFilePage getFileUpload(WebDrone drone)
File upload page pop up object.

Parameters:
drone - WebDrone browser client
repositoryBrowsing - true if we are doing repository browsing
Returns:
SharePage page object response

getFileUpdate

public static UpdateFilePage getFileUpdate(WebDrone drone,
                                           String version,
                                           boolean editOffLine)
File upload page pop up object.

Parameters:
drone - WebDrone browser client
version - the number of the original document
editOffLine - mode status
Returns:
UpdateFilePage page object response

createSite

public static CreateSitePage createSite(WebDrone drone)
Create site pop up page object.

Parameters:
drone - WebDrone
Returns:
SharePage page object response

isDocumentLibraryPage

public static boolean isDocumentLibraryPage(String pageName)
Checks if pageName is document library.

Parameters:
pageName - current page name
Returns:
true if match document library page id

getPageName

public static final String getPageName(String url)
Extracts the String value from the last occurrence of slash in the url.

Parameters:
url - String url.
Returns:
String page title

getNewFolderPage

public static NewFolderPage getNewFolderPage(WebDrone drone)
New folder page pop up object.

Parameters:
drone - WebDrone browser client
repositoryBrowsing - true if we are creating a folder in the Repository browser
Returns:
NewFolderPage page object response

getLibraryPage

public static SharePage getLibraryPage(WebDrone drone)
Get a share library page by its type. Checks if its a DocumentLibraryPage or Repository using the url to confirm which library type page to return.

Parameters:
drone - WebDrone
Returns:
SharePage response


Copyright © 2013. All Rights Reserved.