/* * This file is part of the LibreOffice project. * * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. * * This file incorporates work covered by the following license notice: * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed * with this work for additional information regarding copyright * ownership. The ASF licenses this file to you under the Apache * License, Version 2.0 (the "License"); you may not use this file * except in compliance with the License. You may obtain a copy of * the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
/** * returns an instance of _NumberingLevel * @param log the log writer * @param tParam the test parameters * @param propertyValues a PropertyValue[] which should contain all properties of com.sun.star.text.NumberingLevel
*/ public _NumberingLevel(LogWriter log, TestParameters tParam, PropertyValue[] propertyValues){
/** * This method checks the PropertyValue for completeness. If one or more properties * are missing the return value is FALSE, else TRUE * @return returns TRUE if PropertyValue[] is complete, else FALSE
*/ publicboolean testPropertyArray(){
boolean status = true; try{
// iterate over the given property array and remove it from the must list for (int i = 0; i < PropertyArray.length; i++){
String propertyName=PropertyArray[i].Name;
if ( NumberingLevel.containsKey(propertyName) ) {
NumberingLevel.remove(propertyName);
} else { if ( status ) {
log.println("FAILED: com.sun.star.text.NumberingLevel -> " + "found not described property:");
}
status = false;
log.println("-> '" + propertyName + "'");
}
}
// get rest of properties and check if they are optional if (! NumberingLevel.isEmpty()){ for (Map.Entry<String,Boolean> e : NumberingLevel.entrySet()) { // if some elements are not optional -> failed if (!e.getValue().booleanValue()) {
if ( status ) {
log.println("FAILED: com.sun.star.text.NumberingLevel -> " + "could not find not optional property:");
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.