/*
(non-Javadoc)

@see
qc.automation.framework.widget.IElement#waitForAttributeEqualTo(java.
lang.String, java.lang.String)
199175
public void waitForAttributeEqualTo(String attributeName, String attributeValue) throws WidgetTimeoutException {
		waitForAttributeEqualTo(attributeName, attributeValue, getGUIDriver().getMaxRequestTimeout());
	}
1272716
public void notifyBeforeEvaluation(String expr) {
        if (getEvaluationListeners() == null)
            return;
        for (EvaluationListener listener: getEvaluationListeners()) {
            listener.beforeEvaluation(this, expr);
        }
    }
401966
public void addLessOrEqualThanField(String attribute, Object value)
    {
		// PAW
		// addSelectionCriteria(FieldCriteria.buildNotGreaterCriteria(attribute, value, getAlias()));
		addSelectionCriteria(FieldCriteria.buildNotGreaterCriteria(attribute, value, getUserAlias(attribute)));
    }
140207
public void waitForElementNotPresent(final long time) throws WidgetException {
		try {
			waitForCommand(new ITimerCallback() {

				@Override
				public boolean execute() throws WidgetException {
					return !isElementPresent();
				}

				@Override
				public String toString() {
					return "Waiting for element with locator " + locator + " to not be present";
				}
			}, time);
		} catch (Exception e) {
			throw new WidgetException("Error while waiting for element to be not present", locator, e);
		}
	}
1101138
public void write_attribute_asynch(DeviceAttribute[] attribs, CallBack cb) throws DevFailed {
        deviceProxyDAO.write_attribute_asynch(this, attribs, cb);
    }
149623
public static ExpectedCondition<Boolean> textToBeEqualsToExpectedValue(final By locator, final String value) {
        return new ExpectedCondition<Boolean>() {
            /**
             * {@inheritDoc}
             */
            @Override
            public Boolean apply(@Nullable WebDriver driver) {
                try {
                    final WebElement element = driver.findElement(locator);
                    if (element != null && value != null) {
                        return !((element.getAttribute(VALUE) == null || !value.equals(element.getAttribute(VALUE).trim())) && !value.equals(element.getText().replaceAll("\n", "")));
                    }
                } catch (final Exception e) {
                }
                return false;
            }
        };
    }
863519
@Override
	public void waitForText(long time) throws WidgetException, WidgetTimeoutException {
		waitForCommand(new ITimerCallback() {

			@Override
			public boolean execute() throws WidgetException {
				String val = getText();

				if (val == null || val.equals(""))
					return false;

				return true;
			}

			@Override
			public String toString() {
				return "Waiting for text on the element with the " + "locator: " + locator;
			}

		}, time);

	}
876918
@Override
	public void waitForElementPresent() throws WidgetException {
		try {
			waitForElementPresent(getGUIDriver().getMaxRequestTimeout());
		} catch (Exception e) {
			throw new WidgetException("Error while waiting for element to be present", locator, e);
		}
	}
464748
public final void waitForCheckpoint()
                    throws ObjectManagerException
    {
        if (Tracing.isAnyTracingEnabled() && trace.isEntryEnabled())
            trace.entry(this, cclass
                        , "waitForCheckpoint"
                            );

        if (!testInterfaces) {
            if (Tracing.isAnyTracingEnabled() && trace.isEntryEnabled())
                trace.exit(this, cclass
                           , "waitForCheckpoint via InterfaceDisabledException"
                                );
            throw new InterfaceDisabledException(this
                                                 , "waitForCheckpoint");
        } // if (!testInterfaces).   

        objectManagerState.waitForCheckpoint(true);

        if (Tracing.isAnyTracingEnabled() && trace.isEntryEnabled())
            trace.exit(this, cclass
                       , "waitForCheckpoint"
                            );
    }
774656
public boolean waitForView(View view){
		View viewToWaitFor = waitForView(view, Timeout.getLargeTimeout(), true, true);
		if(viewToWaitFor != null) {
			return true;
		}
		
		return false;
		
	}
1313601
@Override
    public java.util.concurrent.Future<GetQueueAttributesResult> getQueueAttributesAsync(String queueUrl, java.util.List<String> attributeNames,
            com.amazonaws.handlers.AsyncHandler<GetQueueAttributesRequest, GetQueueAttributesResult> asyncHandler) {

        return getQueueAttributesAsync(new GetQueueAttributesRequest().withQueueUrl(queueUrl).withAttributeNames(attributeNames), asyncHandler);
    }
613290
protected void checkAttribute(String attribute) {
        if (!hasAttribute(attribute)) {
            String sb = "Attribute: '" + attribute + "' is not defined in model: '" + getModelClass() + ". "
                    + "Available attributes: " +getAttributeNames();
            throw new IllegalArgumentException(sb);
        }
    }
1356676
public void addEqualToField(String attribute, String fieldName)
    {
		// PAW
		// FieldCriteria c = FieldCriteria.buildEqualToCriteria(attribute, fieldName, getAlias());
		FieldCriteria c = FieldCriteria.buildEqualToCriteria(attribute, fieldName, getUserAlias(attribute));
        addSelectionCriteria(c);
    }
714969
protected static boolean locateMatchingAttributeValue(final String attrName, final String attrValue,
                                                          final Map<String, List<Object>> attributes) {
        return locateMatchingAttributeValue(attrName, attrValue, attributes, true);
    }
1210681
@Override
    public void _waitForNonStaleResults(Duration waitTimeout) {
        theWaitForNonStaleResults = true;
        timeout = ObjectUtils.firstNonNull(waitTimeout, getDefaultTimeout());
    }
877638
@Override
    int read_attribute_asynch_i(final String a, final boolean fwd, final int rid) throws DevFailed {
	synchronized (this) {
	    final Iterator it = elements.iterator();
	    while (it.hasNext()) {
		final GroupElement e = (GroupElement) it.next();
		if (e instanceof GroupDeviceElement || fwd) {
		    e.read_attribute_asynch_i(a, fwd, rid);
		}
	    }
	    return rid;
	}
    }
5276
@Override
    public int compareTo(ControllerRouteModel rElem) {
        if (rElem == null) {
            throw new NullPointerException("Cannot compare to null");
        }

        if (rElem.equals(this)) {
            return 0;
        }

        int compare = getPath().compareTo(rElem.getPath());

        if(compare == 0){
            compare = getHttpMethod().compareTo(rElem.getHttpMethod());

            if(compare == 0){
                compare = getMethodName().compareTo(rElem.getMethodName());
            }
        }

        return compare;
    }