|
AAX SDK
2.3.1
Avid Audio Extensions Development Kit
|
#include <AAX_IParameter.h>
The base interface for all normalizable plug-in parameters.
This class is an outside interface for an arbitrarily typed parameter. The subclasses of this generic interface hold the parameter's state and conversion functionality.
Public Member Functions | |
| virtual | ~AAX_IParameter () |
| Virtual destructor. More... | |
| virtual AAX_IParameterValue * | CloneValue () const =0 |
| Clone the parameter's value to a new AAX_IParameterValue object. More... | |
| virtual void | SetType (AAX_EParameterType iControlType)=0 |
| Sets the type of this parameter. More... | |
| virtual AAX_EParameterType | GetType () const =0 |
| Returns the type of this parameter as an AAX_EParameterType. More... | |
| virtual void | SetOrientation (AAX_EParameterOrientation iOrientation)=0 |
| Sets the orientation of this parameter. More... | |
| virtual AAX_EParameterOrientation | GetOrientation () const =0 |
| Returns the orientation of this parameter. More... | |
| virtual void | SetTaperDelegate (AAX_ITaperDelegateBase &inTaperDelegate, bool inPreserveValue)=0 |
| Sets the parameter's taper delegate. More... | |
| virtual void | SetDisplayDelegate (AAX_IDisplayDelegateBase &inDisplayDelegate)=0 |
| Sets the parameter's display delegate. More... | |
Identification methods | |
| virtual AAX_CParamID | Identifier () const =0 |
| Returns the parameter's unique identifier. More... | |
| virtual void | SetName (const AAX_CString &name)=0 |
| Sets the parameter's display name. More... | |
| virtual const AAX_CString & | Name () const =0 |
| Returns the parameter's display name. More... | |
| virtual void | AddShortenedName (const AAX_CString &name)=0 |
| Sets the parameter's shortened display name. More... | |
| virtual const AAX_CString & | ShortenedName (int32_t iNumCharacters) const =0 |
| Returns the parameter's shortened display name. More... | |
| virtual void | ClearShortenedNames ()=0 |
| Clears the internal list of shortened display names. More... | |
Automation methods | |
| virtual bool | Automatable () const =0 |
| Returns true if the parameter is automatable, false if it is not. More... | |
| virtual void | SetAutomationDelegate (AAX_IAutomationDelegate *iAutomationDelegate)=0 |
| Sets the automation delegate (if one is required) More... | |
| virtual void | Touch ()=0 |
| Signals the automation system that a control has been touched. More... | |
| virtual void | Release ()=0 |
| Signals the automation system that a control has been released. More... | |
Taper methods | |
| virtual void | SetNormalizedValue (double newNormalizedValue)=0 |
| Sets a parameter value using it's normalized representation. More... | |
| virtual double | GetNormalizedValue () const =0 |
| Returns the normalized representation of the parameter's current real value. More... | |
| virtual void | SetNormalizedDefaultValue (double normalizedDefault)=0 |
| Sets the parameter's default value using its normalized representation. More... | |
| virtual double | GetNormalizedDefaultValue () const =0 |
| Returns the normalized representation of the parameter's real default value. More... | |
| virtual void | SetToDefaultValue ()=0 |
| Restores the state of this parameter to its default value. More... | |
| virtual void | SetNumberOfSteps (uint32_t numSteps)=0 |
| Sets the number of discrete steps for this parameter. More... | |
| virtual uint32_t | GetNumberOfSteps () const =0 |
| Returns the number of discrete steps used by the parameter. More... | |
| virtual uint32_t | GetStepValue () const =0 |
| Returns the current step for the current value of the parameter. More... | |
| virtual double | GetNormalizedValueFromStep (uint32_t iStep) const =0 |
| Returns the normalized value for a given step. More... | |
| virtual uint32_t | GetStepValueFromNormalizedValue (double normalizedValue) const =0 |
| Returns the step value for a normalized value of the parameter. More... | |
| virtual void | SetStepValue (uint32_t iStep)=0 |
| Returns the current step for the current value of the parameter. More... | |
Display methods | |
This functionality is most often used by GUIs, but can also be useful for state serialization. | |
| virtual bool | GetValueString (AAX_CString *valueString) const =0 |
| Serializes the parameter value into a string. More... | |
| virtual bool | GetValueString (int32_t iMaxNumChars, AAX_CString *valueString) const =0 |
| Serializes the parameter value into a string, size hint included. More... | |
| virtual bool | GetNormalizedValueFromBool (bool value, double *normalizedValue) const =0 |
| Converts a bool to a normalized parameter value. More... | |
| virtual bool | GetNormalizedValueFromInt32 (int32_t value, double *normalizedValue) const =0 |
| Converts an integer to a normalized parameter value. More... | |
| virtual bool | GetNormalizedValueFromFloat (float value, double *normalizedValue) const =0 |
| Converts a float to a normalized parameter value. More... | |
| virtual bool | GetNormalizedValueFromDouble (double value, double *normalizedValue) const =0 |
| Converts a double to a normalized parameter value. More... | |
| virtual bool | GetNormalizedValueFromString (const AAX_CString &valueString, double *normalizedValue) const =0 |
| Converts a given string to a normalized parameter value. More... | |
| virtual bool | GetBoolFromNormalizedValue (double normalizedValue, bool *value) const =0 |
| Converts a normalized parameter value to a bool representing the corresponding real value. More... | |
| virtual bool | GetInt32FromNormalizedValue (double normalizedValue, int32_t *value) const =0 |
| Converts a normalized parameter value to an integer representing the corresponding real value.  More... | |
| virtual bool | GetDoubleFromNormalizedValue (double normalizedValue, double *value) const =0 |
| Converts a normalized parameter value to a double representing the corresponding real value. More... | |
| virtual bool | GetStringFromNormalizedValue (double normalizedValue, AAX_CString &valueString) const =0 |
| Converts a normalized parameter value to a string representing the corresponding real value. More... | |
| virtual bool | GetStringFromNormalizedValue (double normalizedValue, int32_t iMaxNumChars, AAX_CString &valueString) const =0 |
| Converts a normalized parameter value to a string representing the corresponding real, size hint included. value. More... | |
| virtual bool | SetValueFromString (const AAX_CString &newValueString)=0 |
| Converts a string to a real parameter value and sets the parameter to this value. More... | |
Typed accessors | |
| virtual bool | GetValueAsBool (bool *value) const =0 |
| Retrieves the parameter's value as a bool. More... | |
| virtual bool | GetValueAsInt32 (int32_t *value) const =0 |
| Retrieves the parameter's value as an int32_t. More... | |
| virtual bool | GetValueAsFloat (float *value) const =0 |
| Retrieves the parameter's value as a float. More... | |
| virtual bool | GetValueAsDouble (double *value) const =0 |
| Retrieves the parameter's value as a double. More... | |
| virtual bool | GetValueAsString (AAX_IString *value) const =0 |
| Retrieves the parameter's value as a string. More... | |
| virtual bool | SetValueWithBool (bool value)=0 |
| Sets the parameter's value as a bool. More... | |
| virtual bool | SetValueWithInt32 (int32_t value)=0 |
| Sets the parameter's value as an int32_t. More... | |
| virtual bool | SetValueWithFloat (float value)=0 |
| Sets the parameter's value as a float. More... | |
| virtual bool | SetValueWithDouble (double value)=0 |
| Sets the parameter's value as a double. More... | |
| virtual bool | SetValueWithString (const AAX_IString &value)=0 |
| Sets the parameter's value as a string. More... | |
Host interface methods | |
| virtual void | UpdateNormalizedValue (double newNormalizedValue)=0 |
| Sets the parameter's state given a normalized value. More... | |
|
inlinevirtual |
Virtual destructor.
|
pure virtual |
Clone the parameter's value to a new AAX_IParameterValue object.
The returned object is independent from the AAX_IParameter. For example, changing the state of the returned object will not result in a change to the original AAX_IParameter.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
Referenced by AAX_CMonolithicParameters::GenerateCoefficients().
|
pure virtual |
Returns the parameter's unique identifier.
This unique ID is used by the Parameter Manager and by outside applications to uniquely identify and target control messages. This value may not be changed after the parameter has been constructed.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
Referenced by AAX_CMonolithicParameters::AddSynchronizedParameter(), and AAX_CMonolithicParameters::GenerateCoefficients().
|
pure virtual |
Sets the parameter's display name.
This name is used for display only, it is not used for indexing or identifying the parameter This name may be changed after the parameter has been created, but display name changes may not be recognized by all AAX hosts.
| [in] | name | Display name that will be assigned to the parameter |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Returns the parameter's display name.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Sets the parameter's shortened display name.
This name is used for display only, it is not used for indexing or identifying the parameter These names show up when the host asks for shorter length parameter names for display on Control Surfaces or other string length constrained situations.
| [in] | name | Shortened display names that will be assigned to the parameter |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Returns the parameter's shortened display name.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Clears the internal list of shortened display names.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Returns true if the parameter is automatable, false if it is not.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
Referenced by AAX_CMonolithicParameters::AddSynchronizedParameter().
|
pure virtual |
Sets the automation delegate (if one is required)
| [in] | iAutomationDelegate | A reference to the parameter manager's automation delegate interface |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Signals the automation system that a control has been touched.
Call this method in response to GUI events that begin editing, such as a mouse down. After this method has been called you are free to call SetNormalizedValue() as much as you need, e.g. in order to respond to subsequent mouse moved events. Call Release() to free the parameter for updates from other controls.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Signals the automation system that a control has been released.
Call this method in response to GUI events that complete editing, such as a mouse up. Once this method has been called you should not call SetNormalizedValue() again until after the next call to Touch().
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Sets a parameter value using it's normalized representation.
For more information regarding normalized values, see Parameter Manager
| [in] | newNormalizedValue | New value (normalized) to which the parameter will be set |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Returns the normalized representation of the parameter's current real value.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Sets the parameter's default value using its normalized representation.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Returns the normalized representation of the parameter's real default value.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Restores the state of this parameter to its default value.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Sets the number of discrete steps for this parameter.
Stepped parameter values are useful for discrete parameters and for "jumping" events such as mouse wheels, page up/down, etc. The parameter's step size is used to specify the coarseness of those changes.
| [in] | numSteps | The number of steps that the parameter will use |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Returns the number of discrete steps used by the parameter.
See SetNumberOfSteps() for more information about parameter steps.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Returns the current step for the current value of the parameter.
See SetNumberOfSteps() for more information about parameter steps.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Returns the normalized value for a given step.
See SetNumberOfSteps() for more information about parameter steps.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Returns the step value for a normalized value of the parameter.
See SetNumberOfSteps() for more information about parameter steps.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Returns the current step for the current value of the parameter.
See SetNumberOfSteps() for more information about parameter steps.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Serializes the parameter value into a string.
| [out] | valueString | A string representing the parameter's real value |
| true | The string conversion was successful |
| false | The string conversion was unsuccessful |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Serializes the parameter value into a string, size hint included.
| [in] | iMaxNumChars | A size hint for the size of the string being requested. Useful for control surfaces and other limited area text fields. (make sure that size of desired string also has room for null termination) |
| [out] | valueString | A string representing the parameter's real value |
| true | The string conversion was successful |
| false | The string conversion was unsuccessful |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Converts a bool to a normalized parameter value.
| [in] | value | A value for the parameter |
| [out] | normalizedValue | The normalized parameter value associated with value |
| true | The value conversion was successful |
| false | The value conversion was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Converts an integer to a normalized parameter value.
| [in] | value | A value for the parameter |
| [out] | normalizedValue | The normalized parameter value associated with value |
| true | The value conversion was successful |
| false | The value conversion was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Converts a float to a normalized parameter value.
| [in] | value | A value for the parameter |
| [out] | normalizedValue | The normalized parameter value associated with value |
| true | The value conversion was successful |
| false | The value conversion was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Converts a double to a normalized parameter value.
| [in] | value | A value for the parameter |
| [out] | normalizedValue | The normalized parameter value associated with value |
| true | The value conversion was successful |
| false | The value conversion was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Converts a given string to a normalized parameter value.
| [in] | valueString | A string representing a possible real value for the parameter |
| [out] | normalizedValue | The normalized parameter value associated with valueString |
| true | The string conversion was successful |
| false | The string conversion was unsuccessful |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Converts a normalized parameter value to a bool representing the corresponding real value.
| [in] | normalizedValue | The normalized value to convert |
| [out] | value | The converted value. Set only if conversion is successful. |
| true | The conversion to bool was successful |
| false | The conversion to bool was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Converts a normalized parameter value to an integer representing the corresponding real value.
| [in] | normalizedValue | The normalized value to convert |
| [out] | value | The converted value. Set only if conversion is successful. |
| true | The conversion to int32_t was successful |
| false | The conversion to int32_t was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Converts a normalized parameter value to a float representing the corresponding real value.
| [in] | normalizedValue | The normalized value to convert |
| [out] | value | The converted value. Set only if conversion is successful. |
| true | The conversion to float was successful |
| false | The conversion to float was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Converts a normalized parameter value to a double representing the corresponding real value.
| [in] | normalizedValue | The normalized value to convert |
| [out] | value | The converted value. Set only if conversion is successful. |
| true | The conversion to double was successful |
| false | The conversion to double was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Converts a normalized parameter value to a string representing the corresponding real value.
| [in] | normalizedValue | A normalized parameter value |
| [out] | valueString | A string representing the parameter value associated with normalizedValue |
| true | The string conversion was successful |
| false | The string conversion was unsuccessful |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Converts a normalized parameter value to a string representing the corresponding real, size hint included. value.
| [in] | normalizedValue | A normalized parameter value |
| [in] | iMaxNumChars | A size hint for the size of the string being requested. Useful for control surfaces and other limited area text fields. (make sure that size of desired string also has room for null termination) |
| [out] | valueString | A string representing the parameter value associated with normalizedValue |
| true | The string conversion was successful |
| false | The string conversion was unsuccessful |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Converts a string to a real parameter value and sets the parameter to this value.
| [in] | newValueString | A string representing the parameter's new real value |
| true | The string conversion was successful |
| false | The string conversion was unsuccessful |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Retrieves the parameter's value as a bool.
| [out] | value | The parameter's real value. Set only if conversion is successful. |
| true | The conversion to bool was successful |
| false | The conversion to bool was unsuccessful |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Retrieves the parameter's value as an int32_t.
| [out] | value | The parameter's real value. Set only if conversion is successful. |
| true | The conversion to int32_t was successful |
| false | The conversion to int32_t was unsuccessful |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Retrieves the parameter's value as a float.
| [out] | value | The parameter's real value. Set only if conversion is successful. |
| true | The conversion to float was successful |
| false | The conversion to float was unsuccessful |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Retrieves the parameter's value as a double.
| [out] | value | The parameter's real value. Set only if conversion is successful. |
| true | The conversion to double was successful |
| false | The conversion to double was unsuccessful |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Retrieves the parameter's value as a string.
| [out] | value | The parameter's real value. Set only if conversion is successful. |
| true | The conversion to string was successful |
| false | The conversion to string was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Sets the parameter's value as a bool.
| [out] | value | The parameter's real value. Set only if conversion is successful. |
| true | The conversion from bool was successful |
| false | The conversion from bool was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Sets the parameter's value as an int32_t.
| [out] | value | The parameter's real value. Set only if conversion is successful. |
| true | The conversion from int32_t was successful |
| false | The conversion from int32_t was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Sets the parameter's value as a float.
| [out] | value | The parameter's real value. Set only if conversion is successful. |
| true | The conversion from float was successful |
| false | The conversion from float was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Sets the parameter's value as a double.
| [out] | value | The parameter's real value. Set only if conversion is successful. |
| true | The conversion from double was successful |
| false | The conversion from double was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Sets the parameter's value as a string.
| [out] | value | The parameter's real value. Set only if conversion is successful. |
| true | The conversion from string was successful |
| false | The conversion from string was unsuccessful |
Implemented in AAX_CStatelessParameter, AAX_CParameter< T >, and AAX_CParameter< T >.
|
pure virtual |
Sets the type of this parameter.
See GetType for use cases
| [in] | iControlType | The parameter's new type as an AAX_EParameterType |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Returns the type of this parameter as an AAX_EParameterType.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Sets the orientation of this parameter.
| [in] | iOrientation | The parameter's new orientation |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Returns the orientation of this parameter.
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Sets the parameter's taper delegate.
| [in] | inTaperDelegate | A reference to the parameter's new taper delegate |
| [in] | inPreserveValue |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Sets the parameter's display delegate.
| [in] | inDisplayDelegate | A reference to the parameter's new display delegate |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.
|
pure virtual |
Sets the parameter's state given a normalized value.
This is the second half of the parameter setting operation that is initiated with a call to SetValue(). Parameters should not be set directly using this method; instead, use SetValue().
| [in] | newNormalizedValue | Normalized value that will be used to set the parameter's new state |
Implemented in AAX_CStatelessParameter, and AAX_CParameter< T >.


webdriver_test_tools.pageobject.form module¶
-
class
webdriver_test_tools.pageobject.form.
InputObject
(driver, input_dict)[source]¶ Bases:
webdriver_test_tools.pageobject.base.BasePage
Page object prototype for input elements
-
class
Type
[source]¶ Bases:
object
Set of supported input types
-
CHECKBOX
= 'checkbox'¶
-
EMAIL
= 'email'¶
-
FILE
= 'file'¶
-
NUMBER
= 'number'¶
-
PASSWORD
= 'password'¶
-
RADIO
= 'radio'¶
-
SEARCH
= 'search'¶
-
TEXT
= 'text'¶
-
URL
= 'url'¶
-
SELECT
= 'select'¶
-
TEXTAREA
= 'textarea'¶
-
SUPPORTS_OPTIONS
= ['select', 'radio', 'checkbox']¶ Input types that support the ‘options’ key
-
SUPPORTS_MULTIPLE
= ['select', 'checkbox']¶ Input types that support the ‘multiple’ key
-
-
find_input_element
()[source]¶ Returns the
WebElement
object located byself.locator
Shorthand for
self.find_element(self.locator)
- Returns
WebElement
object for the input
-
find_input_elements
()[source]¶ Returns the list of
WebElement
objects located byself.locator
. Used for input types that can have multiple elements corresponding to it (e.g. radios)Shorthand for
self.find_elements(self.locator)
- Returns
List of
WebElement
objects for the inputs
-
set_value
(value, **kwargs)[source]¶ Set the value of the input
- Parameters
value –
The value to set it to
For radio elements, this should be the value attribute of the radio to select.
For checkbox elements, this value should be a boolean (True=checked, False=unchecked).
For checkbox groups, this value should be a dictionary mapping checkbox input’s
value
attribute to the desired checked state (True = check, False = uncheck).For single select elements, this value should be the value of the option to select.
For multiple select elements, this value should be a list of values of the options to select.
For file inputs, this value should be a filepath to the desired file.
For other input types (text, number, etc) this should be a string representation of the values to enter into it.
Additionally accepts keyword arguments based on the type of input this
InputObject
represents. See the above_set
methods for type-specific optional arguments
-
class
-
class
webdriver_test_tools.pageobject.form.
FormObject
(driver)[source]¶ Bases:
webdriver_test_tools.pageobject.yaml.YAMLParsingPageObject
Page object prototype for forms
Subclasses should set the following attributes:
- Variables
FormObject.YAML_FILE – Path to a YAML file representing the form object. This file is parsed during initialization using
parse_yaml()
and is used to determineFORM_LOCATOR
andSUBMIT_LOCATOR
and createInputObject
instances for each input, which are stored ininputs
FormObject.SUBMIT_SUCCESS_CLASS – (Optional) Page object of modal/webpage/etc that should appear on successful form submission. If subclass set to a subclass of
BasePage
,click_submit()
will return an instance of this object.
The following attributes are determined based on the contents of
YAML_FILE
(or should be set in subclasses ifYAML_FILE
isNone
):- Variables
FormObject.FORM_LOCATOR – Locator for the form element
FormObject.SUBMIT_LOCATOR – Locator for the submit button
The following attribute is set based on the ‘inputs’ key parsed from
YAML_FILE
(or parsed fromINPUT_DICTS
, which should be set in subclasses ifYAML_FILE
isNone
):- Variables
FormObject.inputs – A dictionary mapping input names to the corresponding
InputObject
instances. The keys correspond with thename
keys in the YAML representation of the form (or the ‘name’ keys inINPUT_DICTS
ifYAML_FILE
isNone
)
If
YAML_FILE
isNone
, subclasses must set the following attribute:- Variables
FormObject.INPUT_DICTS – List of input dictionaries. These are used to initialize the
InputObject
instances ininputs
at runtime. These dictionaries use the same syntax as YAML inputs
-
SUBMIT_SUCCESS_CLASS
= None¶
-
FORM_LOCATOR
= None¶
-
SUBMIT_LOCATOR
= None¶
-
INPUT_DICTS
= []¶
-
inputs
= {}¶
-
parse_yaml
(file_path)[source]¶ Parse a YAML representation of the form object and set attributes accordingly
See YAML FormObjects doc for details on syntax.
- Parameters
file_path – Full path to the YAML file
-
no_yaml_init
()[source]¶ Initialize
self.inputs
using values inINPUT_DICTS
-
fill_inputs
(input_map, strict=False)[source]¶ Fill form inputs
- Parameters
input_map – Dictionary mapping input name key to the values to set them to. See
InputObject.set_value()
for value formats for different input typesstrict – (Default = False) If True, throw an exception if a key in
input_map
is not a valid key inself.inputs
. Otherwise throw a warning and continue
-
get_input_values
(name_list=None)[source]¶ Get the current values of form inputs
- Parameters
name_list – (Optional) List of input names to get values for. If unspecified, will get values for all inputs
- Returns
Dictionary mapping names to the value of each input
-
submit_is_enabled
()[source]¶ Short hand function for checking if the submit button is enabled. Useful for forms with JavaScript input validation
- Returns
True if submit is enabled, False if it’s disabled
-
click_submit
()[source]¶ Shorthand function for scrolling to the submit button and clicking it.
If
self.SUBMIT_SUCCESS_CLASS
is set to a subclass ofBasePage
, an instance of that object will be returned


import os
from cloudmesh.common.Shell import Shell
from pprint import pprint
from cloudmesh.common.console import Console
[docs]class WindowsService(object):
[docs] @staticmethod
def delete(name="MongoDB"):
"""
deletes the named service
:param name:
:return:
"""
# use sd delete as posted in piazza
# needs the service to be stopped we guess
os.system(f"sc delete {name}")
[docs] @staticmethod
def status(name="MongoDB"):
"""
returns the status of the named service
:param name:
:return:
"""
# use the sc query and status command as postedin piazz
services = WindowsService.list()
if name in services:
return services[name]["STATE"].lower()
else:
return None
[docs] @staticmethod
def stop(name="MongoDB"):
"""
sops the named service
:param name:
:return:
"""
# use the stop command before you delete it
raise NotImplementedError
# use the Shell.execute or run command to redirect the output and than find the stat in the output
[docs] @staticmethod
def list():
"""
lists the names of the running services
:return:
"""
services = {}
r = Shell.execute("sc", ["query"])
r = r.replace("\r\n", "\n")
entries = r.split("\n\n")
for entry in entries:
attributes = entry.splitlines()
element = {}
for line in attributes:
if ":" in line:
name, value = line.split(":", 1)
name = name.strip()
value = value.strip()
if name == "STATE":
element[name] = value[3:]
else:
element[name] = value
services[element["SERVICE_NAME"]] = element
return services
[docs] @staticmethod
def uninstall(name=None):
"""
uninstalls the named package. The name should be the msi
:param name:
:return:
"""
# we do not know ho to do this from the commadline
raise NotImplementedError
if __name__ == "__main__":
pprint(WindowsService.list())
status = WindowsService.status(name="MongoDB")
print("Status MongoDB", status)
if status is not None:
WindowsService.delete(name="MongoDB")
Console.ok("Deleting the MongoDB service")
else:
Console.ok("Could not find the MongoDB servise")
print("check if MongoDB is no longer in the service list")
status = WindowsService.status(name="MongoDB")
print("Status MongoDB", status)
if status is None:
Console.ok("deleted")
else:
Console.error("MongoDB is in the status", status)


SweetFreeStuff.com
///////////////////////////////////////////
Free Colgate Toothpaste at Rite Aid and CVS
Posted: 23 Nov 2015 11:00 AM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Rite Aid has Colgate Toothpaste Total Advanced 4oz, Optic White 3.5oz, Max
6oz or 2-in-1 4.6oz for $3.50. Use this $0.50 off Colgate Toothpaste
Printable Coupon along with the $3 off Colgate In-Ad coupon (can be found
in store) to make it FREE! CVS has Colgate Max 6oz, Total 4-4.2oz, 2in1
4.6oz or Optic White 3.5oz for $3. Use this $0.50 off Continue reading
Free Colgate Toothpaste at Rite Aid and CVS
The post Free Colgate Toothpaste at Rite Aid and CVS appeared first on
SweetFreeStuff.com.
///////////////////////////////////////////
FREE California Almond Butter Sample
Posted: 23 Nov 2015 09:50 AM PST
http://feedproxy.google.com/&edburner&utm_medium=email
*Site working slow at the moment. Try refreshing if you cant get through.
FREE California Almond Butter Sample
The post FREE California Almond Butter Sample appeared first on
SweetFreeStuff.com.
///////////////////////////////////////////
Free Noh Foods of Hawaii Recipe Book
Posted: 23 Nov 2015 06:07 AM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Free Noh Foods of Hawaii Recipe Book
The post Free Noh Foods of Hawaii Recipe Book appeared first on
SweetFreeStuff.com.
///////////////////////////////////////////
Free Subscription to Shape Magazine
Posted: 23 Nov 2015 04:00 AM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Free Subscription to Shape Magazine
The post Free Subscription to Shape Magazine appeared first on
SweetFreeStuff.com.
///////////////////////////////////////////
Free Alaska Travel Guide
Posted: 23 Nov 2015 01:00 AM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Click where it says Click Here to get to the form. Free Alaska Travel Guide
The post Free Alaska Travel Guide appeared first on SweetFreeStuff.com.
///////////////////////////////////////////
Earn Cash and Prizes for Scanning your Purchases - NCP
Posted: 23 Nov 2015 01:00 AM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Earn Free Cash and Prizes from National Consumer Panel Click Here to Sign
up! As a panel member, the National Consumer Panel will provide you with a
hand-held scanner. Every time you or members of your household shop, youll
use the scanner to scan the barcodes on all of your purchases. Then, once
a Continue reading Earn Cash and Prizes for Scanning your Purchases NCP
The post Earn Cash and Prizes for Scanning your Purchases NCP appeared
first on SweetFreeStuff.com.
///////////////////////////////////////////
Free Centrum VitaMints Multivitamins Sample
Posted: 23 Nov 2015 12:01 AM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Free Centrum VitaMints Multivitamins Sample
The post Free Centrum VitaMints Multivitamins Sample appeared first on
SweetFreeStuff.com.
///////////////////////////////////////////
Free Meow Mix Irresistibles Cat Treats Sample
Posted: 23 Nov 2015 12:00 AM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Upload a video or photo of your most irresistible moment and they will send
you free treats. Free Meow Mix Irresistibles Cat Treats Sample
The post Free Meow Mix Irresistibles Cat Treats Sample appeared first on
SweetFreeStuff.com.
///////////////////////////////////////////
Free 32oz Fountain Drink at Stripes Stores
Posted: 22 Nov 2015 10:11 PM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Coupon good for a free 32oz fountain drink at Stripes Stores. Good through
11/24. Check locations.
The post Free 32oz Fountain Drink at Stripes Stores appeared first on
SweetFreeStuff.com.
///////////////////////////////////////////
Free 2016 Four Paws Calendar (Expired)
Posted: 22 Nov 2015 09:15 PM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Free 2016 Four Paws Calendar
The post Free 2016 Four Paws Calendar (Expired) appeared first on
SweetFreeStuff.com.
///////////////////////////////////////////
Free Purina Beneful IncrediBites Dog Food Sample
Posted: 22 Nov 2015 09:15 PM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Free Purina Beneful IncrediBites Dog Food Sample
The post Free Purina Beneful IncrediBites Dog Food Sample appeared first on
SweetFreeStuff.com.
///////////////////////////////////////////
Free Nordic Naturals Wellness Sample Kit
Posted: 22 Nov 2015 09:00 PM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Click Free Sample on the lower right side of the page,
The post Free Nordic Naturals Wellness Sample Kit appeared first on
SweetFreeStuff.com.
///////////////////////////////////////////
10 Free Pampers Gifts to Grow Points
Posted: 22 Nov 2015 09:00 PM PST
http://feedproxy.google.com/&edburner&utm_medium=email
To login please click here and enter the code: FBQ3THA5X9GIV15 for 10 more
points. (Expires 11/25) (If you need to register, click here to sign up and
receive 100 points!) The Pampers Gifts to Grow Rewards Program rewards you
for choosing Pampers diapers, training pants and wipes for your growing
baby. To start, simply collect the codes Continue reading 10 Free Pampers
Gifts to Grow Points
The post 10 Free Pampers Gifts to Grow Points appeared first on
SweetFreeStuff.com.
///////////////////////////////////////////
Free College Football Team Cling from Hyundai
Posted: 22 Nov 2015 09:00 PM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Free College Football Team Cling from Hyundai
The post Free College Football Team Cling from Hyundai appeared first on
SweetFreeStuff.com.
///////////////////////////////////////////
Free Engagement Ring and Nudge from Ring Cam
Posted: 21 Nov 2015 09:22 PM PST
http://feedproxy.google.com/&edburner&utm_medium=email
Ring Cam will just happen to send your friend card with an ENGAGEMENT RING
telling them that they no longer have an excuse to not get engaged! We will
also tell them that Ring Cams innovated ring box is pretty cool. This is
completely ANONYMOUS and your name will not be on there! Free Engagement
Continue reading Free Engagement Ring and Nudge from Ring Cam
The post Free Engagement Ring and Nudge from Ring Cam appeared first on
SweetFreeStuff.com.


|
Expat is an XML parser library written in C. It is a
stream-oriented parser in which an application registers handlers for
things the parser might find in the XML document (like start tags).
An introductory article on using Expat is available on
xml.com.
This project aims to maintain Expat for both current and future
users while improving the API to allow more reliable and robust access
from "scripting" languages such as Python and Perl. We invite the
community to participate on the mailing lists to help shape the future
of Expat.
News
- 24 March 2012,
Expat 2.1.0 released.
Release 2.1.0 includes security & other bug fixes, new
features, and updated build support.
Security fixes
New features
- Added function XML_SetHashSalt that allows setting an initial
value (salt) for hash calculations (part of the fix for bug 3496608).
- When compiled with XML_ATTR_INFO defined, adds new API member
XML_GetAttributeInfo() that allows retrieving the byte offsets
for attribute names and values (patch 3446384).
- Added CMake build system (bug 2990652, patch 3312568).
- Added run-benchmark target to Makefile.in - relies on testdata
module present in the same relative location as in the repository.
Bug fixes
- Harmful XML_ParserCreateNS suggestion (1742315)
- CVE-2012-1147 - Resource leak in readfilemap.c (2895533)
- Expat build fails on linux-amd64 with gcc version>=4.1 -O3 (1785430)
- Build modifications using autoreconf instead of buildconf.sh (1983953, 2517952, 2517962, 2649838)
- OBJEXT and EXEEXT support while building (2815947, 2884086)
- CVE-2009-3720 - Parser crash with special UTF-8 sequences (1990430)
- xmlwf should return non-zero exit status if not well-formed (2517938)
- Wrong statement about XMLDecl in xmlwf.1 and xmlwf.sgml (2517946)
- Dangling positionPtr after error (2855609)
- CVE-2009-3560 - Buffer over-read and crash in big2_toUtf8() (2894085)
- CVE-2012-1148 - Memory leak in poolGrow (2958794)
- UNEXPECTED_STATE with a trailing "%" in entity value (3010819)
- Unitialized memory returned from XML_Parse (3206497)
- make check fails on mingw-w64 (87849)
- 5 June 2007,
Expat 2.0.1 released.
Release 2.0.1 of the Expat XML parser is a bugfix release
resolving both code and build related issues. Changes include:
- Fixed: The character data handler's calling of XML_StopParser()
was not handled properly; if the parser was stopped and the handler
set to NULL, the parser would segfault.
- Fixed: Expat failed on EBCDIC systems as it assumed some character
constants to be ASCII encoded.
- Minor cleanups of the test harness.
- Minor fixes for xmlwf and example programs.
- Fixes and improvements for the Windows platform.
New Windows directory structure.
- Build fixes for various platforms: HP-UX, Tru64, Solaris 9.
- Build fixes for Unix:
- Refreshed config.sub/config.guess.
- Support both, DESTDIR and INSTALL_ROOT, without relying on GNU-Make specific features.
- Patched configure.in to work better with Intel compiler.
- Fixes to Makefile.in to have make check work correctly.
- Added Open Watcom support.
- 11 January 2006,
Expat 2.0.0 released.
Release 2.0.0 of the Expat XML parser is the end point of the
1.95.X series of releases. The goal was to solidify and stabilize
the implementation of the given API, to add desirable features as
long as they fit with the API, and to keep the API backwards compatible
if extensions were required. Changes include:
- Fixed headers for use from C++.
- XML_GetCurrentLineNumber() and XML_GetCurrentColumnNumber()
now return unsigned integers.
- Added XML_LARGE_SIZE switch to enable 64-bit integers for
byte indexes and line/column numbers.
- Added support for AmigaOS.
- Some mostly minor bug fixes. SF issues include: 1006708,
1021776, 1023646, 1114960, 1156398, 1221160, 1271642.
Old news archive
References & 3rd-party Wrappers
If you know of any additional articles or resources which should be
linked to from this page, please send email to Fred Drake (fdrake@acm.org).
We're especially interested in links to tutorial information and open
source interfaces to Expat from languages other than C.
-
James Clark's original Expat page, for Expat 1.2 and
earlier
-
Introductory article on using Expat on
xml.com
-
LuaExpat is a
wrapper around Expat for the Lua
programming language. The LuaSOAP library is a SOAP implementation
built on top of LuaExpat.
-
Perl's
XML::Parser module is a wrapper built around a
binding to Expat in the XML::Parser::Expat module.
-
Documentation for the Python interface to Expat, part of the
standard documentation for Python.
-
SAXExpat.NET, a .NET
wrapper for Expat, conforming to the
SAX for .NET specifications.
-
The Simple C Expat Wrapper
is a wrapper around Expat that provides a light-weight object model
somewhat like a DOM.
-
C++ Wrappers
for the Expat XML Parser, an article by Tim Smith
providing object-oriented wrappers for Expat. The wrappers use
some MFC-biased naming, but look interesting.
-
Arabica -- an XML Parser toolkit for C++ programmers, with
SAX2 implementations based on several parsers, including Expat.
-
ExpatMM -- C++ interface to Expat
-
SAX2 Wrapper for using Expat in Delphi,
based on
"SAX for Pascal"
interface specs
-
The TclXML project includes a Tcl binding for Expat
-
tDOM is an alternate package providing XML support for Tcl, based in part on
Expat.
-
Article on using Expat from PHP on
<?PHPBuilder?>
(broken into lots of tiny pieces)
-
Objective-C interface to Expat
-
OCaml Expat is a
wrapper around Expat for the Objective Caml language.
-
Ruby interface to Expat
-
XML Tools
2 is an AppleScript scripting addition that allows AppleScript
applications to work with XML data; it is based on Expat.
-
Simkin is an open source
scripting language available under the GNU LGPL. It can be embedded
in XML and supports a DOM-like API backed by Expat.
-
EasySoap is a C++
SOAP implementation which uses Expat.
-
A discussion of another way to manage stateful callbacks, using
Expat as a sample library.
-
The GOBO
project is working on an Eiffel binding for Expat. Development
is active and the package is fully supported in GOBO 3.0 and 3.1,
though there isn't much status information about the Expat bindings
on the website. (Most activity is reportedly on the relevant
mailing lists.)
-
Expat4D is a plug-in
for the 4th Dimension application
framework.
|


Capstone - Fredrick Collins: ICE Reader
Project idea, design, and execution by Fredrick Collins, New England Tech software engineering student, computer enthusiast
Tested and designed primarily on 2014 Volkswagen Jetta 1.8T, for any car made after 1995
Resources are linked below.
Links


CHARLES BROWNING – SLAUGHTER HOUSE
My Father, Charles Henry Browning, was a butcher by trade; at least from the time I was old enough to remember him. Although he had owned a dry farm and managed a grain elevator before I was born. I think those occupations are recorded in his history as recorded by Betsy Browning. I, therefore, will not at this time re-tell those experiences.
My first remembrance was that Dad ran a meat retail department in Larsen’s General Mercantile Store on Main Street in Victor. I would often walk to the store and enjoy spending time with my Dad. He had a refrigeration room that he always kept various dressed out animals hanging there. He almost always had a large wooden pickle barrel in there. I remember that I would ask Dad for a nickel to buy candy and when he said that he didn’t have a nickel, I would reply with, “then can I have a pickle?” That always got a chuckle and a “yes” reply.
Dad had to buy his meat from other slaughterhouses or kill the animal in the field. He also built a small shed out back of the store and did some killing there. I think that new USDA laws finally forbid him from using that shed and frowned on him killing in the field. Finally Dad bought a five acre lot just outside the North West City Limits of Victor. There he built his own slaughterhouse for the purpose of killing his own animals to supply meat for the Butcher shop. I remember watching the construction of the building. The cement was mixed in a small electric cement mixer, poured into wheel barrels, which were pushed by hand, to hand built forms over 2 X 12 planking. The original building was about 24’ X 40’ and was divided into four rooms. The N.W. room was the killing room, the N.E. room was the cutting and wrapping room, the S.W. room was the cooling room and the S.E. room was the refrigeration room. When Dad first started killing there he did all his cutting by hand. My brother Rich was in the army and in one of Mom’s letters to him she told him that Dad was working hard and often came home very tired, with sore aching muscles after cutting an animal by hand. Dad was still running the shop in the store and did the butchering after hours or would have Mom run the shop while he worked at the slaughterhouse. On receiving this letter, Rich found a Sears and Roebuck catalog and with some of the money he had saved, from his military pay, he ordered an electric band saw for Dad. It wasn’t very long after Dad started operation in the slaughterhouse that the decision was made to quit the shop in the grocery store and to go full time with the slaughterhouse. Many people in the valley wanted Dad to do the killing of their animals instead of taking them to the Driggs slaughterhouse. Also, Dad found a lot of requests for him to furnish meat to the restaurants and Dude Ranches in Jackson Hole, Wyoming.
The following summer Dad added a fifth room onto the North end of the slaughterhouse.  In the chicken coop Dad kept approximately 300 laying hens. This kept him with chickens to kill for meat and eggs to sell.
Here are a couple of incidences which happened in connection to the slaughterhouse. I’ll add others at a later date.
On the South West corner of the block where we lived was a hotel. About the same time Dad was getting his slaughterhouse going, a family by the name of Burnside became the manager of that hotel. Mr. Burnside also had a hobby of raising and running sled dogs. At first he kenneled them just behind our lot. That soon caused a problem with many citizens of the community as the dogs were always barking day and night. To add to those problems, the dogs often broke out of their kennel and caused a nuisance in town. He was finally told that he had to kennel his dogs outside the city limits.
Mr. Burnsides set up his Dog Kennels, just across the road from Dad's slaughter house. The dogs would still get loose and almost every time they did they would go for Dad's chickens. At first it was just a few chickens, but one night four or five dogs got out killing almost 200 chickens. I remember helping with the cleaning of all those chickens. Dad saved what we could. Dad then took the chickens up to Mr. Burnsides and told him he had just purchased them. Mr. Burnsides had to buy a freezer to keep them in. It was just a few days later that Dad and I went to the Slaughter House, and as we got out of the pickup, we could hear chickens squawking. Dad jumped the fence and ran for the coop door.   The dog was killed instantly by the crushing force. I had just arrived at the fence to see the whole thing take place. I was impressed with the strength Dad had. Mr. Burnsides had to buy a few more chickens that day. From then on he also tried to keep his kennels in better repair.
About a half mile south of Dad’s slaughterhouse lived a man named Ceiler Westover and his sister.  Dad often had Ceiler do some work around the slaughterhouse and would pay him a little. Often the pay would be with some meat to help them out. Dad had tracks on the ceiling of the slaughterhouse on which he would hang meat and could easily move the meat to and from the killing room, the cooling room, the refrigeration room or to the a loading area. One day, Dad was cutting meat and asked Ceiler to bring a half of beef from the cooling room. As Ceiler was pushing it along the track, Dad looked up to see that Ceiler had not switched the track properly and the switch was open. Dad hollered, but Ceiler was coming too fast to stop. Dad ran and as the roller came off the track, Dad caught the beef in his arms.  I remember watching the blood running down his neck and him carrying the half beef to the cutting table and putting it down with out it touching the floor. That was another impressive moment of Dad's strength.
When Dad had put the fence around the slaughter house property he had put the entrance gate coming to the South West corner of the building. As a result, every time he wanted to load out meat, he had to open the gates to drive in, and then close the gates so no animals could get out. He decided to change the gates to the East side. The gates consisted of two gates, each about 10 feet long, swung off heavy posts. The post stood about 10 feet high and had two cross logs at the top going from one post to the other. This made quite a heavy frame, but Dad thought he could move the frame without disassembling it. The upright post had also been set in concrete and about 3 to 4 feet deep. We therefore dug around the concrete and planned to break the cement off with a sludge hammer. Dad and I were just finishing digging around the second post when the whole frame began to move. Dad hollered for us to move as he thought the frame might be tipping over, but to our amazement Ceiler had squatted down and put his arms around the first post and was lifting the post, and cement out of the hole. Dad and I both watched in amazement as to Ceiler’s strength.


Request
into queue.Request
s into queue.Request
into the end of the loading queue.Request
s into the end of the loading queue.ImageView
that could be used with
ImageLoader
.Param
wrapper for Bitmap
object.Bitmap
would be compressed into byte array according
to the specified Bitmap.CompressFormat
.URLConnection
.HttpURLConnection
.URI
is in queue.Param
wrapper for raw data.Queue
interface.Param
into an HTTP-entity of full value - adds all
needed headers and boundaries before and after and transforms all this into a byte array.Thread
where the cache queue is executed.Request.getComposedURI()
but already transformed into URL
.Thread
where the queue is executed.Request
and returns the
index of the first occurrence.Request
by it's
URI
and returns the index of the first occurrence.Request
into the specified position.InputStream
and does the loading.android.support.v4.util.LruCache
.Request
in queue, or null.Cache
implementation - does nothing.Request
.Request
has just failed.Request
has just successfully finished.Request
has just began.Request
.InputStream
and sets
content length inside the passed Request
object -
Request.setResponseContentLength(long)
.Request
objects for loaders.Request
from queue.Request
from queue at a specified index.Request
from queue.URI
.Request
from the cache loading queue.Request
from the loading queue.DataLoader.LoadingListener
.URI
of the request destination
List
<Param
> with request parameters
(for HTTP POST and GET)
HTTP method - basically it is determined automatically, GET is in priority
size of the response data in bytes (value of HTTP response 'content-length' header,
file size, etc.; -1 if the data size is unknown or unavailable)
DataLoader.stopWorking()
clear queue by DataLoader.clearQueue()
DataLoader.stopWorking()
clear queue by DataLoader.clearQueue()
clear cache by Cache.clear()
clear queue queue by ImageLoader.clearCacheQueue()
ImageLoader
's listeners when
is removed from interface (in AsyncImageView.onDetachedFromWindow()
calls AsyncImageView.setImageLoader(ImageLoader)
with NULL).Bitmap
would be compressed into byte array according
to the specified Bitmap.CompressFormat
in BitmapParam.getFormat()
.Bitmap
would be compressed into byte array according
to the specified Bitmap.CompressFormat
.DataLoader.LoadingListener
's methods are called in main thread
(inter-thread communication is already embed in loaders).ImageLoader
.URI
inside itself - doesn't start loading itself.ImageLoader
's listeners when
is removed from interface (in AsyncImageView.onDetachedFromWindow()
calls AsyncImageView.setImageLoader(ImageLoader)
with NULL).ImageLoader
.Thread
.Param
wrapper for plain text data.OutputStream
.Param
into the specified OutputStream
as an HTTP-entity (with all headers, Black-Jack and others...)


These example apps demonstrate special use-cases of the Twilio Video JS SDK.
To try the quickstart, click here
This app demonstrates the Bandwidth Constraints API, which can be used to control the send-side bandwidth of the media that is published to the Room.
This app demonstrates a way to apply filters to the LocalVideoTrack. The filtered LocalVideoTrack can then be used to connect to a Room.
This app demonstrates a way to capture a snapshot of the LocalVideoTrack using the HTMLCanvasElement.
This app demonstrates a way to select the media devices to be used for capturing local media.
This app demonstrates the Codec Preferences API, which can be used to specify the send-side audio and video codec preferences while connecting to a Room.
This app demonstrates how to capture your screen so that you can share it with other Participants in the Room. This example requires that the browser support the getDisplayMedia API.
This app demonstrates the Dominant Speaker API for Group or Small Group Rooms. In order to run this example, please go to the Programmable Video Settings in the Twilio Console and select the Room Type as Group or Group-Small.
This app demonstrates the Room's Reconnection States and Events which can be used to notify the user when Twilio Video SDK is reconnecting to the Room, probably due to network interruptions or handoffs.
This app demonstrates the Network Quality API for Group or Small Group Rooms. In order to run this example, please go to the Programmable Video Settings in the Twilio Console and select the Room Type as Group or Group-Small.
This app demonstrates how to enable/disable your LocalTracks and handle the events on the remote side.
This app demonstrates the RemoteParticipant Reconnection States and Events which can be used to update your application when somebody else is reconnecting to the Room.
This app demonstrates the DataTracks API which can be used to send low latency messages to subscribers. It can also be used to create "whiteboarding" sessions as demonstrated in Draw With Twilio.
This app demonstrates the manual modes of the clientTrackSwitchOffControl and contentPreferencesMode features. Which can be used to efficiently utilize CPU and bandwidth.
This app demonstrates the default (automatic) modes of the clientTrackSwitchOffControl and contentPreferencesMode features. Which can be used to efficiently utilize CPU and bandwidth.


by Mr Rogers
Signup requires
Over the past 2 years we've seen more and more fake accounts show up.
At first there were a pile that appeard to come from China who did not get activated. (this may be when I put in the Captcha)
Then a few folks from maybe Germany who got as far as adding art that had an ad for Viagra.
Most recently we got over 500 accounts created in 2 months, almost certainly by real people. They do not have art but they clearly were trying to get the message out.
Seems like a potential client problem that we should, at least, think about.
I need your help to find a solution.


stakeholders¶
This wiki was funded by Oregon Department of Transportation (ODOT) to assist Oregon MPOs and other stakeholders who would like to use the VE-RSPM for local scenario planning and strategic assessment. This technical resource replaces previous resource guides on strategic models, namely the 2014 RSPM User’s Guide published by ODOT.
Strategic models are a key component of ODOT’s S-T-O-RM Analysis Toolkit, detailed in Figure 1. Strategic models are useful for exploratory testing. MPOs can use strategic models to evaluate how their region’s transportation system will perform in the future under different scenarios. Strategic models are designed for sensitivity testing, or ‘what if’ analyses to help planners understand the relative effect of changes to transportation and land use policy, investments, and programs. Strategic models differ from other travel demand models that support planning in most urban areas. Strategic models are less detailed but consider a wider range of potential policies and outcomes.
FIGURE 1. ODOT’S S-T-O-RM ANALYSIS TOOLKIT ![Oregon STORM framework](https://github.com/ORScenPlg/VETechWiki/blob/main/media/OR_STORM.jpg) Source: ODOT
Oregon MPOs can use strategic models to support the Oregon Sustainable Transportation Initiative (OSTI), an integrated statewide effort to reduce greenhouse gas, or GHG, emissions from transportation. The initiative was developed to support the state-mandated goal of achieving GHG levels that are 75% below 1990 levels by 2050.
OSTI is being led by several state agencies: ODOT, the Oregon Department of Land Conservation and Development (DLCD) in consultation with the Department of Environmental Quality, the Oregon Department of Energy, and many stakeholder committees made up of businesspeople, elected officials and residents of communities across the state.
More information on why MPOs should conduct scenario planning and strategic assessment can be accessed here: [link to plg-side wiki] All technical resources, including this technical wiki are accessed through the ODOT Scenario Planning website. (https://www.oregon.gov/odot/Planning/Pages/Strategic-Assessment.aspx)


The perfect personal assistant. Relaxr does your job for you so you can enjoy life as it is meant to be.
" Relaxr changed my life. I 've been able to travel the world, spend limited time working and my boss keeps thanking me for crushing work. "
- Amanda, Intuit
Sign Up Now!
Relaxr
Copyright 2015. Relaxr.


This page is about miscellaneous HTML things, but you might also be interested in links and images
You can use UTF-8 to count in Turkish:
There are three reserved characters in HTML: < > and &. You should always use HTML entities for these characters


If the import data does not contain a region, the region selected below will be used.
The jump host and software profile are optional.
{{ edit_field(form.region, field_width="col-sm-4", class="form-control") }}
{{ edit_field(form.jump_host, field_width="col-sm-4", class="form-control") }}
{{ edit_field(form.software_profile, field_width="col-sm-4", class="form-control", placeholder="Optional") }}
Import Instructions
Click Import Instructions for more information.
- Paste the import data onto the text window below.
- The first row is the header which identifies the data being imported.
- Mandatory header fields are hostname, ip, and connection (acceptable values: 'telnet' or 'ssh').
- Acceptable header fields are hostname, region, location, roles, ip, username, password, connection, port, and enable_password.
- The second row onwards are import data which must match the header and the data fields must be comma delimited.
- The following data fields roles, ip, and port may contain multiple values.
- If a data field contains multiple values, they must be separated by comma(s) and the data field must be double-quoted.
- If a data field does not contain any value, leave it blank.
- If no username and password is specified, the default host username and password defined on CSM Server will be used.
- The enable_password field is only needed for IOS and IOS XE devices.
- Acceptable characters for hostname and region are a-z, A-Z, 0-9, and (). -_
hostname,region,location,roles,ip,username,password,connection,port,enable_password <- header
myhost1,California USA,blg 20,,<IP_ADDRESS>,johnsmith,john123,telnet,, <- blank for empty fields
myhost2,California USA,blg 20,PE,<IP_ADDRESS>,davidsmith,david123,ssh,"2033,2034",
{{ edit_field(form.data_list, field_width="col-sm-12", spellcheck="false", rows="10", class="form-control") }}


Park Hill offers up bright, open floorplans, high quality construction and appliance as well as proximity to everything you'll need. Restaurants and cafes. Recreation centres and sports complexes.
30,967 and growing! This area northwest of the Township is home to the Civic Facility, Willowbrook Recreation Centre, and Langley Events Centre. This vibrant and growing community features burgeoning new neighbourhoods that provide housing, parks, and ample shopping opportunities.
The Township of Langley is largely a suburban community, but, while the center is increasingly urban, the periphery (particularly in the South and Southeast) maintains its agricultural nature. The neighbourhoods of Willoughby and Walnut Grove are quite suburban, and feature large numbers of big-box stores, the Willowbrook Shopping Centre, and the Famous Players Colossus Theatre Complex.
Willoughby continues to be an area of residential and commercial growth. Yorkson Community Park will see the opening of three new sports fields and a dog off-leash park. Roadway and intersection improvements including traffic signals will be completed at 80 Avenue, 211 Street, 212 Street and 216 Street to support routes as part of the interchange at 216 Street and Highway 1. A water reservoir will be constructed at 73A Avenue and 204 Street as part of GVWD projects.


Three Rafale jets handed over to India: Government
The first batch of four Rafale jets will arrive in India by May 2020
by PTIThree Rafale fighter jets have been handed over to the Indian Air Force (IAF) and are being used to train IAF pilots and technicians in France, the government said on Wednesday.
India and France signed an €7.87 billion (₹ 59,000 crore approximately) deal in September 2016 for 36 Rafale jets.
While the first Rafale jet was handed over to India on October 8, the first batch of four Rafale jets will arrive in India by May 2020.


Guidance
Types of apprenticeships that you can apply for in the insurance sector.
This level 4 higher apprenticeship trains you to work in the insurance sector in a claims, broking or underwriting technician or team leader/supervisor role.
The role of the technicians is to provide support to all types of insurance work including:
The role of the team leaders and supervisors is to guide a team of people resolving queries and problems, providing clear goals and developing your teams’ professional and technical capabilities.
If you complete the higher apprenticeship, you can progress to membership of the Chartered Insurance Institute. You could then complete a professional qualification which offers a fast track route onto chartered studies.
This progression can lead to a specialist role in Insurance. It’s also possible to enter a higher education course in a subject related to insurance, or other financial services.
For more information, watch these videos:-
Progression from level 2 to 4 apprenticeships Paving the way to chartership Career focus
This is a higher level insurance apprenticeship.
You could train in roles like:
You can become an apprentice in England if you’re:
Published: 21 March 2014


Something I’ve been waiting for so long finally shows the sign that is coming to realization. The government of Steem starting to power down the biggest stake ever happened in the blockchain, and the owner of the uncompetitive government has already completed his personal power down, and moved all the fund to an exchange account.
 Secured from what? Likely not the theft, but the seemingly dangerous proposal of hardfork that is going to nullify the huge stake.
Powering down all the SP and moving all the fund to exchange, while telling the community that they are not going to run away with it, sounds exactly like those famous Wall St. investors telling the public to avoid cryptocurrency at all cost, but buying Bitcoin so hard while they still can behind the stage.
This is probably the biggest FUD I’ve ever seen in the Steem community and a handful of wise stakeholders seems starting to power down as well. Whether the government will eventually selling to crash the market or not, I don’t see any bull sign for Steem for most of the time this year, and this is gonna be a long year for Steem.
Posted from my blog with SteemPress : https://fr3eze.vornix.blog/10-cent-steem-is-not-that-far-away/
This page is synchronized from the post: ‘10 cent Steem is not that far away’


Sandbox¶
This sandbox contains code that is for various reasons not ready to be included in statsmodels proper. It contains modules from the old stats.models code that have not been tested, verified and updated to the new statsmodels structure: cox survival model, mixed effects model with repeated measures, generalized additive model and the formula framework. The sandbox also contains code that is currently being worked on until it fits the pattern of statsmodels or is sufficiently tested.
All sandbox modules have to be explicitly imported to indicate that they are not yet part of the core of statsmodels. The quality and testing of the sandbox code varies widely.
Examples¶
There are some examples in the sandbox.examples folder. Additional examples are directly included in the modules and in subfolders of the sandbox.
Module Reference¶
Time Series analysis tsa
¶
In this part we develop models and functions that will be useful for time
series analysis. Most of the models and function have been moved to
statsmodels.tsa
.
Moving Window Statistics¶
Most moving window statistics, like rolling mean, moments (up to 4th order), min, max, mean, and variance, are covered by the functions for Moving (rolling) statistics/moments in Pandas.
|
moving order statistics |
|
moving window mean |
|
moving window variance |
|
non-central moment |
Regression and ANOVA¶
The following two ANOVA functions are fully tested against the NIST test data
for balanced one-way ANOVA. anova_oneway
follows the same pattern as the
oneway anova function in scipy.stats but with higher precision for badly
scaled problems. anova_ols
produces the same results as the one way anova
however using the OLS model class. It also verifies against the NIST tests,
with some problems in the worst scaled cases. It shows how to do simple ANOVA
using statsmodels in three lines and is also best taken as a recipe.
|
|
|
The following are helper functions for working with dummy variables and generating ANOVA results with OLS. They are best considered as recipes since they were written with a specific use in mind. These function will eventually be rewritten or reorganized.
|
convert array of categories to dummy variables by default drops dummy variable for last category uses ravel, 1d only |
|
create dummy continuous variable |
creates product dummy variables from 2 columns of 2d array |
|
|
drop names from a list of strings, names to drop are in space delimited list does not change original list |
|
convert string formula to data dictionary |
The following are helper functions for group statistics where groups are defined by a label array. The qualifying comments for the previous group apply also to this group of functions.
|
|
|
convert labels based on multiple variables or string labels to unique index labels 0,1,2,…,nk-1 where nk is the number of distinct labels |
|
use ndimage to get fast mean and variance |
|
|
|
uses np.bincount, assumes factors/labels are integers |
Additional to these functions, sandbox regression still contains several examples, that are illustrative of the use of the regression models of statsmodels.
Systems of Regression Equations and Simultaneous Equations¶
The following are for fitting systems of equations models. Though the returned parameters have been verified as accurate, this code is still very experimental, and the usage of the models will very likely change significantly before they are added to the main codebase.
|
Seemingly Unrelated Regression |
|
Two-Stage Least Squares for Simultaneous equations |
Miscellaneous¶
Descriptive Statistics Printing¶
|
Signs test |
|
Prints descriptive statistics for one or multiple variables. |
Original stats.models¶
None of these are fully working. The formula framework is used by cox and mixed.
Mixed Effects Model with Repeated Measures using an EM Algorithm
statsmodels.sandbox.mixed
Cox Proportional Hazards Model
statsmodels.sandbox.cox
Generalized Additive Models
statsmodels.sandbox.gam
Formula
statsmodels.sandbox.formula


Welcome! Looks like it's your first time using Zappem
Zappem requires a MongoDB database to work. Before you continue, you'll need to install a MongoDB database on this computer or somewhere you have network access to.
If you have brew
, you can install MongoDB with the following command:
brew install mongodb
Or click Get MongoDB below to download the installer.


Help Us Create A Future of Love
with Wellness & Education
WE ARE JUST GETTING STARTED
Please help us achieve our first goal of $250,000 to start building our educational platform.
$ 5
$ 25
$ 50
$ 100
$ 250
& MORE
The Ageless Foundation is a 501(c)(3) nonprofit organization which makes all donations to us tax-deductible.
We Are Making A Difference
"I can’t fully describe Andrew-because amazing is an understatement. Andrew has taken my 13 year old son under his wing.  Andrew doesn’t tell him how to change his mindset, he shows him. Andrew is giving him the tools for a more positive outlook on life. My son now has an older brother that he always wanted. Deep conversations, keeping it real and holding him accountable. It’s only been 3 months and my son is a completely different kid. Andrews light shines bright. We are fortunate to have met him and looking forward to the future of The Ageless Foundation."
- Monica Wrzesinski
"I have known Amy for over 29 years. Amy’s work ethic is beyond compare and her motto is “where I come from, there is simply no substitute for hard work and putting in time.” Her achievements, hard work, and motivation is increasingly rare. She is an excellent leader and committed to making herself and the world better! Amy not only has a strong work ethic, but her personality is unmatched. She completely goes out of her way to help others and is never looking for anything in return. She fights for the “small guy” and believes every one should be treated the same. Her passion and enthusiasm to help others is a shining light and beacon that you cannot miss!"
- Maura Noska, Bridge Development Partners
"Andrew is incredible. He has not only helped guide my life, but many others as well. The Ageless Foundation is where it’s at! You are in good hands with Andrew."
- Ross Robbins, Executive Board
"From the first time I had a conversation with Andrew, I knew he was full of knowledge, insight, and love. Everything he teaches, all the tools he uses, are not only highly researched through conversations, or by studying experts, he used them on himself first to completely change his life. I personally have felt better mentally, physically, and spiritually by following the “AGELESS” way. Through Andrew’s guidance, I know that I can make ANYTHING happen! Andrew has taught me to always love myself first and that anything is possible."
- Ashley Francis, Project Manager
"Don’t be fooled, Ageless has transformed and changed the way I go about my day to day life."
- Ryan Chandler, Onward Boxing
"Andrew strives for greatness and his energy brings out the greatness in his friends, family, and colleagues."
- Marques Miles, 4x NAACP Image Award Winner
"Amy and Andrew are both amazing people. They both provide unlimited education on multiple topics and keep you motivated to do great things with yourself while keeping a positive mindset."
- Student
"I have known Andrew my entire life and can honestly say that I am proud of what he is creating with The Ageless Foundation and Ageless company."
- Alyssa Mannaioni, Administrative Assistant
Stay Connected With Us Weekly
Filled with knowledge, adventures and updates on The Ageless Foundation


Apache™ FOP: XSL-FO Input
Basic Help for Using XML, XSLT, and XSL-FO
Overview
Apache™ FOP uses XSL-FO as input. It is the responsibility of the user to make sure that the XSL-FO submitted to FOP is correct. The tutorial items presented here are not comprehensive, but are of the FAQ variety. Another good FAQ is Dave Pawson's XSL FAQ.
XML Issues
Special Characters
When entering special (non-ASCII) characters in XML, the general rule is to use the applicable Unicode character instead of trying to use a character entity as you would with HTML. Remember that HTML is an SGML document type. SGML has a limited character set, which requires it to use character entities to represent special characters. One of the improvements of XML over SGML (and thus HTML) is native support for Unicode. Basic XML has only a handful of character entities, primarily because it doesn't really need more.
Entities such as ü (u with an umlaut), which work in HTML, will be flagged as undefined entities unless you define them yourself in your DTD. Use the corresponding Unicode character instead. A list of predefined HTML entities and their Unicode codepoints can be found at Character entity references in HTML 4.
One common example is , used to obtain a non-breaking space in HTML. In XML, use   instead.
For other non-ASCII characters, such as the Euro symbol, checkbox, etc., see the Unicode Reference By Name document that is found at the Unicode Consortium site.
After finding the correct Unicode codepoint to represent the character, use XML Character References to put the character into your source XML, XSLT or FO. See the non-breaking-space comments above for an example of the syntax using decimal notation. The following hexadecimal example will result in a Euro sign:
€
Getting your XML correctly encoded is only part of the job. If you want the character to display or print correctly (and you probably do), then the selected font must contain the necessary glyph. Because of differences between font encoding methods, and limitations in some font technologies, this can be a troublesome issue, especially for symbol characters. The FOP example file Base-14 Font Character Mapping is a very useful resource in sorting these issues out for the Base-14 fonts. For other fonts, use font editing sofware or operating system utilities (such as the Character Map in most Windows platforms) to determine what characters the font supports.
An alternative to encoding the character and making it available through a font is to use an embedded graphic to represent the character: GIF, PNG, SVG, etc.
Entity Characters
The handful of basic XML character entities that do exist are the ampersand, apostrophe, less-than, greater-than, and single-quote characters. These are needed to distinguish markup tags from content, and to distinguish character entities from content. To avoid parser complaints about illegal characters and entities in your input, ensure that ampersands in text and attributes are written as &, "<" is written as <, and ">" as >. It is not necessary everywhere, but it is wise to do so anyway, just to be sure.
Most XML parsers will provide a line number and sometimes a column number for offending characters.
Review the XML Specification or a good tutorial for details of the XML file format.
Encoding Issues
If the parser complains about illegal bytes or characters in the input, or there are unexpected characters in the output, this is usually the result of a character encoding problem. See the XSL FAQ for additional information. Many software packages that produce XML, including XSLT processors, use UTF-8 encoding as a default. If you view their output with something not aware of the encoding, like Notepad for Win95/98/ME/NT, funny characters are displayed. A � is a giveaway.
XSLT Issues
Current Date and Time
XSL-FO does not currently have a function for retrieving the current date and time. However, in some cases, XSLT can be used to place the current date and time into the XSL-FO document as it is generated.
One possibility is to use the exslt date and time extension.
Another possibility is to use java or javascript (or perhaps some other language). Here is an example, using java, that works with Xalan. First, create the appropriate namespace:
<xsl:stylesheet version="1.0" ... xmlns:java="http://xml.apache.org/xslt/java" exclude-result-prefixes="java" ...
Next, use the java language to retrieve and format the current date and time. Here is an example template:
<xsl:template match="TodaysDate"> <xsl:value-of select="java:format(java:java.text.SimpleDateFormat.new ('MMMM d, yyyy, h:mm:ss a (zz)'), java:java.util.Date.new())"/> </xsl:template>
XSL-FO Issues
Vertical Centering
To vertically center an image, table, or other item, use display-align="center". See display-align Compliance for implementation status. Here is a small, self-contained document centering an image on a page:
<?xml version="1.0"?> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"> <fo:layout-master-set> <fo:simple-page-master master-name="content" page-width="210mm" page-height="297mm"> <fo:region-body/> </fo:simple-page-master> </fo:layout-master-set> <fo:page-sequence master-reference="content"> <fo:flow flow-name="xsl-region-body"> <fo:table table-layout="fixed" width="100%"> <fo:table-column column-width="proportional-column-width(1)"/> <fo:table-body> <fo:table-row height="297mm"> <fo:table-cell display-align="center"> <fo:block text-align="center"> <fo:external-graphic src="fop.jpg"/> </fo:block> </fo:table-cell> </fo:table-row> </fo:table-body> </fo:table> </fo:flow> </fo:page-sequence> </fo:root>
Horizontal Centering (Tables)
To center a table horizontally, one possibility is to add one column on the left and one on the right which pad the table so that the visible part is centered:
<?xml version="1.0"?> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"> <fo:layout-master-set> <fo:simple-page-master master-name="content" page-width="210mm" page-height="297mm"> <fo:region-body/> </fo:simple-page-master> </fo:layout-master-set> <fo:page-sequence master-reference="content"> <fo:flow flow-name="xsl-region-body"> <fo:table table-layout="fixed" width="100%"> <fo:table-column column-width="proportional-column-width(1)"/> <fo:table-column column-width="100mm"/> <fo:table-column column-width="proportional-column-width(1)"/> <fo:table-body> <fo:table-row> <fo:table-cell column-number="2"> <fo:block>foo</fo:block> </fo:table-cell> </fo:table-row> </fo:table-body> </fo:table> </fo:flow> </fo:page-sequence> </fo:root>
If your table is more complicated, or if defining borders on individual cells becomes too much work, use the code above and nest your table within the middle cell.
Right-Aligning (Tables)
To right-align a table, you can use the same approach as above for centering tables. Just remove the last table-column element which causes all the left-over space not used by the columns with a fixed column-width to be assigned to the first column which effectively right-aligns the table.
Recto/Verso Static Content Differences
One frequent request is that static content be different between recto pages (right-side or odd-numbered pages typically) and verso pages(left-side or even-numbered pages typically). For example, you may wish to place the page number on the "outer" side of each page. There are examples in the FO distribution and in the XSL FAQ FO section.
First, define a page master with alternating pages masters for odd and even pages. Then specify appropriate regions in these page masters, giving them different names. Use these names to put different static content in these regions. Here is a self-contained demonstration:
<?xml version="1.0"?> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"> <fo:layout-master-set> <fo:simple-page-master master-name="even" page-height="297mm" page-width="210mm" margin-top="20mm" margin-bottom="20mm" margin-left="25mm" margin-right="25mm"> <fo:region-body margin-bottom="20mm"/> <fo:region-after region-name="footer-even" extent="20mm"/> </fo:simple-page-master> <fo:simple-page-master master-name="odd" page-height="297mm" page-width="210mm" margin-top="20mm" margin-bottom="20mm" margin-left="25mm" margin-right="25mm"> <fo:region-body margin-bottom="20mm"/> <fo:region-after region-name="footer-odd" extent="20mm"/> </fo:simple-page-master> <fo:page-sequence-master master-name="document"> <fo:repeatable-page-master-alternatives> <fo:conditional-page-master-reference odd-or-even="even" master-reference="even"/> <fo:conditional-page-master-reference odd-or-even="odd" master-reference="odd"/> </fo:repeatable-page-master-alternatives> </fo:page-sequence-master> </fo:layout-master-set> <fo:page-sequence master-reference="document"> <fo:static-content flow-name="footer-even"> <fo:block text-align="start"><fo:page-number/></fo:block> </fo:static-content> <fo:static-content flow-name="footer-odd"> <fo:block text-align-last="end"><fo:page-number/></fo:block> </fo:static-content> <fo:flow flow-name="xsl-region-body"> <fo:block/> <fo:block break-before="page"/> </fo:flow> </fo:page-sequence> </fo:root>
Making the First Page Special
To get a special header on the first page, one possibility is to insert it into the flow instead of the static content. Alternatively, use a page master referring to different page masters for the first page and the rest. Here is a code sample:
<?xml version="1.0"?> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"> <fo:layout-master-set> <fo:simple-page-master master-name="first" page-height="297mm" page-width="210mm" margin-top="20mm" margin-bottom="20mm" margin-left="25mm" margin-right="25mm"> <fo:region-body margin-bottom="20mm"/> <fo:region-after region-name="footer-first" extent="20mm"/> </fo:simple-page-master> <fo:simple-page-master master-name="rest" page-height="297mm" page-width="210mm" margin-top="20mm" margin-bottom="20mm" margin-left="25mm" margin-right="25mm"> <fo:region-body margin-bottom="20mm"/> <fo:region-after region-name="footer-rest" extent="20mm"/> </fo:simple-page-master> <fo:page-sequence-master master-name="document"> <fo:repeatable-page-master-alternatives> <fo:conditional-page-master-reference page-position="first" master-reference="first"/> <fo:conditional-page-master-reference page-position="rest" master-reference="rest"/> </fo:repeatable-page-master-alternatives> </fo:page-sequence-master> </fo:layout-master-set> <fo:page-sequence master-reference="document"> <fo:static-content flow-name="footer-first"> <fo:block text-align="center">First page.</fo:block> </fo:static-content> <fo:static-content flow-name="footer-rest"> <fo:block text-align-last="center">Other page.</fo:block> </fo:static-content> <fo:flow flow-name="xsl-region-body"> <fo:block/> <fo:block break-before="page"/> <fo:block break-before="page"/> </fo:flow> </fo:page-sequence> </fo:root>
Blank Pages
Sometimes it is desirable to insert blank pages within your output, starting, for example, a new chapter on an odd page or an even page. A blank page can be forced by using break-before="page-even" or similar properties, or by a force-page-count="end-on-odd" on a page sequence.
To write "This page is intentionally left blank" (or something similar) on an intentionally blank page, first define a conditional page master with a page master specific for blank pages. This allows you to specify static content for blank pages (by definition, a page is blank if no content from a flow is rendered on the page). Omit your normal headers and footers, and use (for example) an extended header to print the "..left blank" statement:
<?xml version="1.0"?> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"> <fo:layout-master-set> <fo:simple-page-master master-name="normal" page-height="297mm" page-width="210mm" margin-top="20mm" margin-bottom="20mm" margin-left="25mm" margin-right="25mm"> <fo:region-body margin-bottom="20mm"/> <fo:region-after region-name="footer-normal" extent="20mm"/> </fo:simple-page-master> <fo:simple-page-master master-name="blank" page-height="297mm" page-width="210mm" margin-top="20mm" margin-bottom="20mm" margin-left="25mm" margin-right="25mm"> <fo:region-body/> <fo:region-before region-name="header-blank" extent="297mm"/> </fo:simple-page-master> <fo:page-sequence-master master-name="document"> <fo:repeatable-page-master-alternatives> <fo:conditional-page-master-reference blank-or-not-blank="not-blank" master-reference="normal"/> <fo:conditional-page-master-reference blank-or-not-blank="blank" master-reference="blank"/> </fo:repeatable-page-master-alternatives> </fo:page-sequence-master> </fo:layout-master-set> <fo:page-sequence master-reference="document" force-page-count="end-on-even"> <fo:static-content flow-name="footer-normal"> <fo:block text-align="center">Normal footer</fo:block> </fo:static-content> <fo:static-content flow-name="header-blank"> <fo:block space-before="100mm" text-align-last="center"> Intentionally left blank.</fo:block> </fo:static-content> <fo:flow flow-name="xsl-region-body"> <fo:block/> </fo:flow> </fo:page-sequence> </fo:root>
Preformatting Content
Sometimes it is desirable to retain linebreaks and hard spaces, and to get preformatted text to pass through without being changed. The XSL-FO specification provides some properties for this: white-space-collapse and linefeed-treatment. In FOP, use white-space-collapse="false" on an enclosing block.
Total Document Pages
It is frequently desirable to know the total number of pages in a document and to use that number within the document. For example, you might wish to show the page number on the first page as being "page 1 of 12".
To accomplish this in XSL 1.0, place an empty block with an id at the end of the flow:
<fo:flow ...> ... <fo:block id="last-page"/> </fo:flow>
Get the number of the last page as follows:
<fo:page-number-citation ref-id="last-page"/>
This does not work in certain situations: multiple page sequences, an initial page number other than 1, or forcing a certain page count, thereby producing blank pages at the end.
In XSL 1.1, you get another option to do this: make sure an "id" is set on the page-sequence and reference it using fo:page-number-citation-last. First, the page-sequence:
<fo:page-sequence id="seq1" ...
After that, reference the last page the page-sequence generates:
<fo:page-number-citation-last ref-id="seq1"/>
The FOP library provides a method to get the total page count after an FO document has been rendered. One possibility is to implement your own wrapper to do a dummy rendering, inquire the total page count and then perform the real rendering, passing the total page count to the XSLT processor to splice it into the generated FO. For example:
import org.apache.fop.apps.*; import org.xml.sax.*; import java.io.*; import javax.xml.transform.*; import javax.xml.transform.sax.*; import javax.xml.transform.stream.*; class rendtest { private static FopFactory fopFactory = FopFactory.newInstance(); private static TransformerFactory tFactory = TransformerFactory.newInstance(); public static void main(String args[]) { OutputStream out; try { //Load the stylesheet Templates templates = tFactory.newTemplates( new StreamSource(new File(args[1]))); //First run (to /dev/null) out = new org.apache.commons.io.output.NullOutputStream(); FOUserAgent foUserAgent = fopFactory.newFOUserAgent(); Fop fop = fopFactory.newFop(MimeConstants.MIME_PDF, foUserAgent, out); Transformer transformer = templates.newTransformer(); transformer.setParameter("page-count", "#"); transformer.transform(new StreamSource(new File(args[0])), new SAXResult(fop.getDefaultHandler())); //Get total page count String pageCount = Integer.toString(driver.getResults().getPageCount()); //Second run (the real thing) out = new java.io.FileOutputStream(args[2]); out = new java.io.BufferedOutputStream(out); try { foUserAgent = fopFactory.newFOUserAgent(); fop = fopFactory.newFop(MimeConstants.MIME_PDF, foUserAgent, out); transformer = templates.newTransformer(); transformer.setParameter("page-count", pageCount); transformer.transform(new StreamSource(new File(args[0])), new SAXResult(fop.getDefaultHandler())); } finally { out.close(); } } catch( Exception e) { e.printStackTrace(); } } }
Declare and use the parameter "page-count" in your XSLT.
Aligning Regions
Although it may seem counterintuitive, the regions on a page may overlap. Defining a certain body region does not automatically constrain other regions. Instead, this has to be done explicitly. Sometimes for creative reasons it may be desirable to have the regions overlap. Otherwise, you will want to set them up so that the header does not overlap body content or the body extend into the footer.
Assuming you wish to keep the regions separate, if you have a header region with an extent of 20mm, you should define a margin for the body region of at least 20mm too. Otherwise the header content may overwrite some stuff in the body region. This applies similarly to the extent of the after region and the bottom margin of the body region.
Drawing Lines
It is frequently desirable to draw lines in a document, as separators, side bars or folding marks. There are several possibilities:
- Horizontal lines can be drawn using fo:leader.
- Use a solid border on a suitable fo:block. This will work for horizontal and vertical lines only.
- Insert a graphic. GIF, PNG SVG, whatever.
Validating XSL-FO
RenderX has provided an Unofficial DTD for FO Documents, which may be helpful in validating general FO issues.
FOP also maintains an Unofficial FOP Schema in the FOP Subversion Repository. This document can be used either to validate against the FO standard, or against the actual FOP implementation. See the notes near the beginning of the document for instructions on how to use it.
Producing landscape pages
Pages in landscape format can easily be produced by exchanging the page-height and page-width values of a simple-page-master element.
<fo:layout-master-set> <fo:simple-page-master master-name="A4-portrait" page-height="29.7cm" page-width="21cm" [..]> <fo:region-body/> </fo:simple-page-master> <fo:simple-page-master master-name="A4-landscape" page-height="21cm" page-width="29.7cm" [..]> <fo:region-body/> </fo:simple-page-master> </fo:layout-master-set>
External Resources
Resources needed by an XSL-FO file that are external to it (graphics, for example), are defined in the XSL-FO standard as being of type "uri-specification". This is defined in the standard at Section 5.11 Property Datatypes, which includes a link to the URI standard itself. Refer to the XSL-FO and URI standards themselves for more detailed instructions.
URIs may be either absolute or relative to a base URI. (See FOP: Configuration for information on setting the base URI for a FOP session). Here is an example referencing an external-graphic that is relative to the base URI:
<fo:external-graphic src="url('images/logo.jpg')"/>
Here is an example referencing an external-graphic that is an absolute URI on a local filesystem:
fo:external-graphic src="url('file:///d:/images/logo.jpg')"/>


Feather
Feather Icons
Simply beautiful open source icons
activity
airplay
alert-circle
alert-octagon
alert-triangle
align-center
align-justify
align-left
align-right
anchor
aperture
arrow-down
arrow-down-circle
arrow-down-left
arrow-down-right
arrow-left
arrow-left-circle
arrow-right
arrow-right-circle
arrow-up
arrow-up-circle
arrow-up-left
arrow-up-right
at-sign
award
bar-chart
bar-chart-2
battery
battery-charging
bell
bell-off
bluetooth
bold
book
book-open
bookmark
box
briefcase
calendar
camera
camera-off
cast
check
check-circle
check-square
chevron-down
chevron-left
chevron-right
chevron-up
chevrons-down
chevrons-left
chevrons-right
chevrons-up
chrome
circle
clipboard
clock
cloud
cloud-drizzle
cloud-lightning
cloud-off
cloud-rain
cloud-snow
code
codepen
command
compass
copy
corner-down-left
corner-down-right
corner-left-down
corner-left-up
corner-right-down
corner-right-up
corner-up-left
corner-up-right
cpu
credit-card
crop
crosshair
database
delete
disc
dollar-sign
download
download-cloud
droplet
edit
edit-2
edit-3
external-link
eye
eye-off
facebook
fast-forward
feather
file
file-minus
file-plus
file-text
film
filter
flag
folder
folder-minus
folder-plus
git-branch
git-commit
git-merge
git-pull-request
github
gitlab
globe
grid
hard-drive
hash
headphones
heart
help-circle
home
image
inbox
info
instagram
italic
layers
layout
link
link-2
linkedin
list
loader
lock
log-in
log-out
mail
map
map-pin
maximize
maximize-2
menu
message-circle
message-square
mic
mic-off
minimize
minimize-2
minus
minus-circle
minus-square
monitor
moon
more-horizontal
more-vertical
move
music
navigation
navigation-2
octagon
package
paperclip
pause
pause-circle
percent
phone
phone-call
phone-forwarded
phone-incoming
phone-missed
phone-off
phone-outgoing
pie-chart
play
play-circle
plus
plus-circle
plus-square
pocket
power
printer
radio
refresh-ccw
refresh-cw
repeat
rewind
rotate-ccw
rotate-cw
rss
save
scissors
search
send
server
settings
share
share-2
shield
shield-off
shopping-bag
shopping-cart
shuffle
sidebar
skip-back
skip-forward
slack
slash
sliders
smartphone
speaker
square
star
stop-circle
sun
sunrise
sunset
tablet
tag
target
terminal
thermometer
thumbs-down
thumbs-up
toggle-left
toggle-right
trash
trash-2
trending-down
trending-up
triangle
truck
tv
twitter
type
umbrella
underline
unlock
upload
upload-cloud
user
user-check
user-minus
user-plus
user-x
users
video
video-off
voicemail
volume
volume-1
volume-2
volume-x
watch
wifi
wifi-off
wind
x
x-circle
x-square
zap
zap-off
zoom-in
zoom-out


Version 1.9
Sleep mode (Loggin services & Sleep Mode)
"Keep gps on" formerly known as "Sleep mode" was moved to "GPS status" widget. Previously keep gps on could be accessed via Settings or via monitoring widgets. In current version, "GPS status" can enable keep gps on which will be used widely for application.