Remove visual noise from dbaccess

Change-Id: I1130439e5883672b4ca462838d72197acd6bc1f2
Reviewed-on: https://gerrit.libreoffice.org/8251
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
This commit is contained in:
Alexander Wilms 2014-02-25 18:11:51 +01:00 committed by Caolán McNamara
parent f6e0d356b7
commit 2a33953f6e
49 changed files with 270 additions and 270 deletions

View File

@ -40,7 +40,7 @@ import org.junit.After;
import org.junit.Before;
import org.junit.Test;
import static org.junit.Assert.*;
// ------------------------------------------
/** complex test case for Base's application UI
*/
@ -56,13 +56,13 @@ public class ApplicationController extends TestCase
super();
}
// --------------------------------------------------------------------------------------------------------
public String getTestObjectName()
{
return getClass().getName();
}
// --------------------------------------------------------------------------------------------------------
private void impl_closeDocument()
{
if (m_database != null)
@ -74,7 +74,7 @@ public class ApplicationController extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
private void impl_switchToDocument(String _documentURL) throws java.lang.Exception
{
// close previous database document
@ -101,7 +101,7 @@ public class ApplicationController extends TestCase
docModel.getCurrentController());
}
// --------------------------------------------------------------------------------------------------------
@Before
@Override
public void before() throws java.lang.Exception
@ -110,7 +110,7 @@ public class ApplicationController extends TestCase
impl_switchToDocument(null);
}
// --------------------------------------------------------------------------------------------------------
@After
@Override
public void after() throws java.lang.Exception
@ -118,7 +118,7 @@ public class ApplicationController extends TestCase
impl_closeDocument();
super.after();
}
// --------------------------------------------------------------------------------------------------------
@Test
public void checkSaveAs() throws Exception, IOException, java.lang.Exception

View File

@ -47,7 +47,7 @@ import org.junit.Before;
import org.junit.Test;
// import org.openoffice.test.OfficeConnection;
import static org.junit.Assert.*;
// ------------------------------------------
/** complex test case for Base's application UI
@ -62,7 +62,7 @@ public class Beamer extends TestCase
super();
}
// --------------------------------------------------------------------------------------------------------
@Before
@Override
public void before() throws Exception, java.lang.Exception
@ -75,14 +75,14 @@ public class Beamer extends TestCase
docModel = UnoRuntime.queryInterface(XModel.class, loadedComponent);
}
// --------------------------------------------------------------------------------------------------------
@After
@Override
public void after()
{
}
// --------------------------------------------------------------------------------------------------------
@Test
public void testBeamer() throws Exception, IOException, java.lang.Exception
{

View File

@ -26,13 +26,13 @@ import java.util.logging.Logger;
import org.junit.After;
import org.junit.Before;
import static org.junit.Assert.*;
// ------------------------------------------
public abstract class CRMBasedTestCase extends TestCase
{
protected CRMDatabase m_database;
// --------------------------------------------------------------------------------------------------------
protected void createTestCase()
{
try
@ -46,7 +46,7 @@ public abstract class CRMBasedTestCase extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
@Before
@Override
public void before()
@ -54,7 +54,7 @@ public abstract class CRMBasedTestCase extends TestCase
createTestCase();
}
// --------------------------------------------------------------------------------------------------------
@After
@Override
public void after()
@ -72,7 +72,7 @@ public abstract class CRMBasedTestCase extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
/** creates a SingleSelectQueryComposer for our connection
*/
protected final XSingleSelectQueryComposer createQueryComposer() throws com.sun.star.uno.Exception

View File

@ -42,7 +42,7 @@ import org.junit.After;
import org.junit.Before;
import org.junit.Test;
import static org.junit.Assert.*;
// ------------------------------------------
/** complex test case for Base's application UI
*/
@ -58,7 +58,7 @@ public class CopyTableWizard extends CRMBasedTestCase
super();
}
// --------------------------------------------------------------------------------------------------------
@After
@Override
@ -88,7 +88,7 @@ public class CopyTableWizard extends CRMBasedTestCase
}
}
// --------------------------------------------------------------------------------------------------------
class CopyThread implements Runnable
{
@ -217,5 +217,5 @@ public class CopyTableWizard extends CRMBasedTestCase
{
}
}
// --------------------------------------------------------------------------------------------------------
}

View File

@ -27,7 +27,7 @@ import connectivity.tools.HsqlDatabase;
// ---------- junit imports -----------------
import org.junit.Test;
import static org.junit.Assert.*;
// ------------------------------------------
public class DataSource extends TestCase
@ -36,7 +36,7 @@ public class DataSource extends TestCase
HsqlDatabase m_database;
connectivity.tools.DataSource m_dataSource;
// --------------------------------------------------------------------------------------------------------
private void createTestCase()
{
try
@ -58,7 +58,7 @@ public class DataSource extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
@Test
public void testRegistrationName()
{

View File

@ -82,7 +82,7 @@ import org.junit.After;
import org.junit.Before;
import org.junit.Test;
import static org.junit.Assert.*;
// ------------------------------------------
public class DatabaseDocument extends TestCase implements com.sun.star.document.XDocumentEventListener
{
@ -98,7 +98,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
private static short STATE_ON_LOAD_RECEIVED = 3;
private short m_loadDocState = STATE_NOT_STARTED;
// ========================================================================================================
/** a helper class which can be used by the Basic scripts in our test documents
* to notify us of events in this document
*/
@ -132,13 +132,13 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
}
};
// ========================================================================================================
private static String getCallbackComponentServiceName()
{
return "org.openoffice.complex.dbaccess.EventCallback";
}
// ========================================================================================================
/** a factory for a CallbackComponent
*/
private class CallbackComponentFactory implements XSingleComponentFactory, XServiceInfo, XComponent
@ -200,7 +200,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
}
};
// ========================================================================================================
private class MacroExecutionApprove implements XInteractionHandler
{
@ -244,8 +244,8 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
}
};
// ========================================================================================================
// --------------------------------------------------------------------------------------------------------
@Before
public void before() throws java.lang.Exception
{
@ -273,7 +273,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
}
}
// --------------------------------------------------------------------------------------------------------
@After
public void after() throws java.lang.Exception
{
@ -298,7 +298,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
super.after();
}
// --------------------------------------------------------------------------------------------------------
private static class UnoMethodDescriptor
{
@ -312,7 +312,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
}
}
// --------------------------------------------------------------------------------------------------------
private void impl_checkDocumentInitState(Object _document, boolean _isInitialized)
{
// things you cannot do with an uninitialized document:
@ -335,7 +335,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
}
}
// --------------------------------------------------------------------------------------------------------
private XModel impl_createDocument() throws Exception
{
final XModel databaseDoc = UnoRuntime.queryInterface(XModel.class, getMSF().createInstance("com.sun.star.sdb.OfficeDatabaseDocument"));
@ -346,14 +346,14 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
return databaseDoc;
}
// --------------------------------------------------------------------------------------------------------
private void impl_closeDocument(XModel _databaseDoc) throws CloseVetoException, IOException, Exception
{
final XCloseable closeDoc = UnoRuntime.queryInterface(XCloseable.class, _databaseDoc);
closeDoc.close(true);
}
// --------------------------------------------------------------------------------------------------------
private XModel impl_createEmptyEmbeddedHSQLDocument() throws Exception, IOException
{
final XModel databaseDoc = UnoRuntime.queryInterface(XModel.class, getMSF().createInstance("com.sun.star.sdb.OfficeDatabaseDocument"));
@ -388,7 +388,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
return databaseDoc;
}
// --------------------------------------------------------------------------------------------------------
@Test
public void testLoadable() throws Exception, IOException
{
@ -397,12 +397,12 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
// there's three methods how you can initialize a database document:
// ....................................................................
// 1. XStorable::storeAsURL
// (this is for compatibility reasons, to not break existing code)
// this test is already made in impl_createEmptyEmbeddedHSQLDocument
// ....................................................................
// 2. XLoadable::load
databaseDoc = UnoRuntime.queryInterface(XModel.class, getMSF().createInstance("com.sun.star.sdb.OfficeDatabaseDocument"));
documentURL = copyToTempFile(documentURL);
@ -423,7 +423,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
assureException( databaseDoc, XLoadable.class, "load", new Object[] { new PropertyValue[0] },
DoubleInitializationException.class );
// ....................................................................
// 3. XLoadable::initNew
impl_closeDocument(databaseDoc);
databaseDoc = impl_createDocument();
@ -439,7 +439,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
DoubleInitializationException.class );
}
// --------------------------------------------------------------------------------------------------------
private PropertyValue[] impl_getMarkerLoadArgs()
{
return new PropertyValue[]
@ -449,7 +449,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
};
}
// --------------------------------------------------------------------------------------------------------
private boolean impl_hasMarker( final PropertyValue[] _args )
{
for ( int i=0; i<_args.length; ++i )
@ -462,7 +462,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
return false;
}
// --------------------------------------------------------------------------------------------------------
private PropertyValue[] impl_getDefaultLoadArgs()
{
return new PropertyValue[]
@ -471,7 +471,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
};
}
// --------------------------------------------------------------------------------------------------------
private PropertyValue[] impl_getMacroExecLoadArgs()
{
return new PropertyValue[]
@ -482,7 +482,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
};
}
// --------------------------------------------------------------------------------------------------------
private int impl_setMacroSecurityLevel(int _level) throws Exception
{
final XMultiServiceFactory configProvider = theDefaultProvider.get(
@ -503,14 +503,14 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
return oldValue;
}
// --------------------------------------------------------------------------------------------------------
private XModel impl_loadDocument( final String _documentURL, final PropertyValue[] _loadArgs ) throws Exception
{
final XComponentLoader loader = UnoRuntime.queryInterface(XComponentLoader.class, getMSF().createInstance("com.sun.star.frame.Desktop"));
return UnoRuntime.queryInterface(XModel.class, loader.loadComponentFromURL(_documentURL, _BLANK, 0, _loadArgs));
}
// --------------------------------------------------------------------------------------------------------
private void impl_storeDocument( final XModel _document ) throws Exception, IOException
{
// store the document
@ -520,7 +520,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
}
// --------------------------------------------------------------------------------------------------------
private XModel impl_createDocWithMacro( final String _libName, final String _moduleName, final String _code ) throws Exception, IOException
{
// create an empty document
@ -535,7 +535,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
return databaseDoc;
}
// --------------------------------------------------------------------------------------------------------
/** tests various aspects of database document "revenants"
*
* Well, I do not really have a good term for this ... The point is, database documents are in real
@ -604,7 +604,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
impl_closeDocument( databaseDoc );
}
// --------------------------------------------------------------------------------------------------------
@Test
public void testDocumentEvents() throws Exception, IOException
{
@ -673,7 +673,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
impl_closeDocument(databaseDoc);
}
// --------------------------------------------------------------------------------------------------------
@Test
public void testGlobalEvents() throws Exception, IOException
{
@ -817,7 +817,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
impl_closeDocument(otherDoc);
}
// --------------------------------------------------------------------------------------------------------
private URL impl_getURL(String _completeURL) throws Exception
{
final URL[] url =
@ -830,7 +830,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
return url[0];
}
// --------------------------------------------------------------------------------------------------------
private void impl_raise(XModel _document)
{
final XFrame frame = _document.getCurrentController().getFrame();
@ -838,7 +838,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
topWindow.toFront();
}
// --------------------------------------------------------------------------------------------------------
private void impl_startObservingEvents(String _context)
{
System.out.println(" " + _context + " {");
@ -852,7 +852,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
}
}
// --------------------------------------------------------------------------------------------------------
private void impl_stopObservingEvents(ArrayList<String> _actualEvents, String[] _expectedEvents, String _context)
{
try
@ -898,13 +898,13 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
}
}
// --------------------------------------------------------------------------------------------------------
int impl_waitForEvent(ArrayList<String> _eventQueue, String _expectedEvent, int _maxMilliseconds)
{
return impl_waitForEvent(_eventQueue, _expectedEvent, _maxMilliseconds, 0);
}
// --------------------------------------------------------------------------------------------------------
int impl_waitForEvent(ArrayList<String> _eventQueue, String _expectedEvent, int _maxMilliseconds, int _firstQueueElementToCheck)
{
synchronized (_eventQueue)
@ -938,7 +938,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
return -1;
}
// --------------------------------------------------------------------------------------------------------
void onDocumentEvent(DocumentEvent _Event)
{
if ("OnTitleChanged".equals(_Event.EventName))
@ -967,7 +967,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
System.out.println(" document event: " + _Event.EventName);
}
// --------------------------------------------------------------------------------------------------------
public void documentEventOccured(DocumentEvent _Event)
{
if ("OnTitleChanged".equals(_Event.EventName))
@ -985,7 +985,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
System.out.println(" global event: " + _Event.EventName);
}
// --------------------------------------------------------------------------------------------------------
public void disposing(EventObject _Event)
{
// not interested in

View File

@ -30,11 +30,11 @@ import com.sun.star.uno.UnoRuntime;
// ---------- junit imports -----------------
import org.junit.Test;
import static org.junit.Assert.*;
// ------------------------------------------
public class Parser extends CRMBasedTestCase
{
// --------------------------------------------------------------------------------------------------------
@Override
protected void createTestCase()
{
@ -50,7 +50,7 @@ public class Parser extends CRMBasedTestCase
}
}
// --------------------------------------------------------------------------------------------------------
@Test
public void checkWhere() throws Exception
{
@ -88,7 +88,7 @@ public class Parser extends CRMBasedTestCase
composer.setQuery( SELECT + queries[i]);
}
}
// --------------------------------------------------------------------------------------------------------
/** verifies that aliases for inner queries work as expected
*/
@Test
@ -133,7 +133,7 @@ public class Parser extends CRMBasedTestCase
"test is bogus!", caughtExpected );
}
// --------------------------------------------------------------------------------------------------------
private void impl_checkParameters( final String _statement, final String[] _expectedParameterNames, final int[] _expectedParameterTypes,final String _context ) throws Exception
{
final XSingleSelectQueryComposer composer = createQueryComposer();
@ -157,7 +157,7 @@ public class Parser extends CRMBasedTestCase
}
}
// --------------------------------------------------------------------------------------------------------
/** verifies that the parser properly recognizes the types of parameters
*/
@Test

View File

@ -34,7 +34,7 @@ import com.sun.star.lang.XMultiServiceFactory;
import org.junit.Before;
import org.junit.Test;
import static org.junit.Assert.*;
// ------------------------------------------
public class PropertyBag extends TestCase
{
@ -152,7 +152,7 @@ public class PropertyBag extends TestCase
System.out.println( "checking PropertySetAccess via sequences" );
createStandardBag( false );
// ---------------------------------
// XPropertyAccess.setPropertyValues
final PropertyValue expectedValues[] =
{
@ -175,7 +175,7 @@ public class PropertyBag extends TestCase
}
}
// ---------------------------------
// XPropertyAccess.getPropertyValues
final PropertyValue currentValues[] = m_access.getPropertyValues();
for ( int i=0; i<currentValues.length; ++i )

View File

@ -29,14 +29,14 @@ import connectivity.tools.CRMDatabase;
// ---------- junit imports -----------------
import org.junit.Test;
import static org.junit.Assert.*;
// ------------------------------------------
public class Query extends TestCase
{
connectivity.tools.HsqlDatabase m_database;
// --------------------------------------------------------------------------------------------------------
private void createTestCase()
{
try
@ -55,12 +55,12 @@ public class Query extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
// private XMultiServiceFactory getFactory()
// {
// return (XMultiServiceFactory)param.getMSF();
// }
// --------------------------------------------------------------------------------------------------------
@Test
public void testQueryColumns()
{

View File

@ -31,13 +31,13 @@ import com.sun.star.sdbc.XResultSet;
// ---------- junit imports -----------------
import org.junit.Test;
import static org.junit.Assert.*;
// ------------------------------------------
public class QueryInQuery extends CRMBasedTestCase
{
private static final String QUERY_PRODUCTS = "query products";
// --------------------------------------------------------------------------------------------------------
@Override
protected void createTestCase()
{
@ -53,7 +53,7 @@ public class QueryInQuery extends CRMBasedTestCase
}
}
// --------------------------------------------------------------------------------------------------------
private void verifyEqualRowSetContent( int _outerCommandType, String _outerCommand, int _innerCommandType, String _innerCommand ) throws SQLException
{
final RowSet outerRowSet = m_database.getDatabase().createRowSet( _outerCommandType, _outerCommand );
@ -80,7 +80,7 @@ public class QueryInQuery extends CRMBasedTestCase
}
}
// --------------------------------------------------------------------------------------------------------
/** executes a SQL statement simply selecting all columns from a query
*/
@Test
@ -91,7 +91,7 @@ public class QueryInQuery extends CRMBasedTestCase
CommandType.QUERY,QUERY_PRODUCTS);
}
// --------------------------------------------------------------------------------------------------------
/** verifies that aliases for inner queries work as expected
*/
@Test
@ -105,7 +105,7 @@ public class QueryInQuery extends CRMBasedTestCase
CommandType.QUERY,QUERY_PRODUCTS);
}
// --------------------------------------------------------------------------------------------------------
/** verifies that aliases for inner queries work as expected
*/
@Test
@ -140,7 +140,7 @@ public class QueryInQuery extends CRMBasedTestCase
caughtExpected );
}
// --------------------------------------------------------------------------------------------------------
@Test
public void checkCyclicReferences() throws ElementExistException, WrappedTargetException, IllegalArgumentException
{
@ -159,7 +159,7 @@ public class QueryInQuery extends CRMBasedTestCase
assertTrue( "executing a query with cyclic nested sub queries should fail!", caughtExpected );
}
// --------------------------------------------------------------------------------------------------------
@Test
public void checkStatementQiQSupport()
{

View File

@ -50,7 +50,7 @@ import java.util.Random;
// ---------- junit imports -----------------
import org.junit.Test;
import static org.junit.Assert.*;
// ------------------------------------------
public class RowSet extends TestCase
{
@ -69,7 +69,7 @@ public class RowSet extends TestCase
XPropertySet m_rowSetProperties;
XParametersSupplier m_paramsSupplier;
// --------------------------------------------------------------------------------------------------------
class ResultSetMovementStress implements Runnable
{
@ -103,7 +103,7 @@ public class RowSet extends TestCase
}
}
}
// --------------------------------------------------------------------------------------------------------
private void createTestCase(boolean _defaultRowSet)
{
if (m_database == null)
@ -135,7 +135,7 @@ public class RowSet extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
/** creates a com.sun.star.sdb.RowSet to use during the test
* @param command
* the command to use for the RowSet
@ -149,7 +149,7 @@ public class RowSet extends TestCase
createRowSet(command, commandType, execute, false);
}
// --------------------------------------------------------------------------------------------------------
/** creates a com.sun.star.sdb.RowSet to use during the test
* @param command
* the command to use for the RowSet
@ -192,7 +192,7 @@ public class RowSet extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
@Test
public void testRowSet() throws java.lang.Exception
{
@ -216,14 +216,14 @@ public class RowSet extends TestCase
testConcurrentAccess(m_resultSet);
}
// --------------------------------------------------------------------------------------------------------
XResultSet createClone() throws SQLException
{
final XResultSetAccess rowAcc = UnoRuntime.queryInterface( XResultSetAccess.class, m_rowSet );
return rowAcc.createResultSet();
}
// --------------------------------------------------------------------------------------------------------
void createStruture() throws SQLException
{
m_database.executeSQL("DROP TABLE \"TEST1\" IF EXISTS");
@ -242,7 +242,7 @@ public class RowSet extends TestCase
connection.refreshTables();
}
// --------------------------------------------------------------------------------------------------------
void testPosition(XResultSet m_resultSet, XRow m_row, int expectedValue, String location) throws SQLException
{
final int val = m_row.getInt(1);
@ -251,7 +251,7 @@ public class RowSet extends TestCase
assertTrue(location + ": value/position are not as expected: " + val + " (val) != " + expectedValue + " (expected)", val == expectedValue);
}
// --------------------------------------------------------------------------------------------------------
void testSequentialPositining(XResultSet _resultSet, XRow _row)
{
try
@ -270,7 +270,7 @@ public class RowSet extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
void testAbsolutePositioning(XResultSet _resultSet, XRow _row)
{
try
@ -288,7 +288,7 @@ public class RowSet extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
void test3(XResultSet clone, XResultSet _resultSet)
{
try
@ -312,7 +312,7 @@ public class RowSet extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
void test4(XResultSet _resultSet)
{
try
@ -339,7 +339,7 @@ public class RowSet extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
void testConcurrentAccess(XResultSet _resultSet)
{
System.out.println("testing Thread");
@ -367,7 +367,7 @@ public class RowSet extends TestCase
fail("testConcurrentAccess failed: " + e);
}
}
// --------------------------------------------------------------------------------------------------------
@Test
public void testRowSetEvents() throws java.lang.Exception
@ -515,7 +515,7 @@ public class RowSet extends TestCase
xComp.dispose();
}
// --------------------------------------------------------------------------------------------------------
private void testCursorMove(Object res, Method _method, RowSetEventListener _evt, boolean _must[], Object args[]) throws java.lang.Exception
{
_evt.clearCalling();
@ -546,7 +546,7 @@ public class RowSet extends TestCase
_evt.clearCalling();
}
// --------------------------------------------------------------------------------------------------------
/** returns the current row count of the RowSet
*/
private int currentRowCount() throws UnknownPropertyException, WrappedTargetException
@ -555,7 +555,7 @@ public class RowSet extends TestCase
return rowCount.intValue();
}
// --------------------------------------------------------------------------------------------------------
/** positions the row set at an arbitrary position between 2 and (current row count - 1)
*/
private int positionRandom() throws SQLException, UnknownPropertyException, WrappedTargetException
@ -566,7 +566,7 @@ public class RowSet extends TestCase
return m_resultSet.getRow();
}
// --------------------------------------------------------------------------------------------------------
/** moves the result set to a random record between 2 and (current row count - 1), and deletes this record
*
* After returning from this method, the row set is still positioned at the deleted record
@ -590,7 +590,7 @@ public class RowSet extends TestCase
return positionBefore;
}
// --------------------------------------------------------------------------------------------------------
@Test
public void testDeleteBehavior() throws Exception
{
@ -603,7 +603,7 @@ public class RowSet extends TestCase
// delete a random row
int deletedRow = deleteRandom();
// .....................................................................................................
// asking for the bookmark of a deleted row should fail
boolean caughtException = false;
try
@ -616,13 +616,13 @@ public class RowSet extends TestCase
}
assertTrue("asking for the bookmark of a deleted row should throw an exception", caughtException);
// .....................................................................................................
// isXXX methods should return |false| on a deleted row
assertTrue("one of the isFoo failed after |deleteRow|", !m_resultSet.isBeforeFirst() && !m_resultSet.isAfterLast() && !m_resultSet.isFirst() && !m_resultSet.isLast());
// note that we can assume that isFirst / isLast also return |false|, since deleteRandom did
// not position on the first or last record, but inbetween
// .....................................................................................................
// check if moving away from this row in either direction yields the expected results
assertTrue("|previous| after |deleteRow| failed", m_resultSet.previous());
final int positionPrevious = m_resultSet.getRow();
@ -635,11 +635,11 @@ public class RowSet extends TestCase
// since the deleted record "vanishs" as soon as the cursor is moved away from it, the absolute position does
// not change with a |next| call here
// .....................................................................................................
// check if the deleted rows really vanished after moving away from them
assertTrue("row count did not change as expected after two deletions", initialRowCount - 2 == currentRowCount());
// .....................................................................................................
// check if the deleted row vanishes after moving to the insertion row
final int rowCountBefore = currentRowCount();
final int deletedPos = deleteRandom();
@ -657,7 +657,7 @@ public class RowSet extends TestCase
m_resultSetUpdate.moveToCurrentRow();
assertTrue("|last| + |deleteRow| + |moveToInsertRow| + |moveToCurrentRow| results in wrong state", m_resultSet.isAfterLast());
// .....................................................................................................
// check if deleting a deleted row fails as expected
deleteRandom();
caughtException = false;
@ -671,7 +671,7 @@ public class RowSet extends TestCase
}
assertTrue("deleting a deleted row succeeded - it shouldn't", caughtException);
// .....................................................................................................
// check if deleteRows fails if it contains the bookmark of a previously-deleted row
m_resultSet.first();
final Object firstBookmark = m_rowLocate.getBookmark();
@ -686,7 +686,7 @@ public class RowSet extends TestCase
assertTrue("XDeleteRows::deleteRows with the bookmark of an already-deleted row failed",
(deleteSuccess.length == 2) && (deleteSuccess[0] != 0) && (deleteSuccess[1] == 0));
// .....................................................................................................
// check if refreshing a deleted row fails as expected
deleteRandom();
caughtException = false;
@ -700,12 +700,12 @@ public class RowSet extends TestCase
}
assertTrue("refreshing a deleted row succeeded - it shouldn't", caughtException);
// .....................................................................................................
// rowUpdated/rowDeleted
deleteRandom();
assertTrue("rowDeleted and/or rowUpdated are wrong on a deleted row", !m_resultSet.rowUpdated() && !m_resultSet.rowInserted());
// .....................................................................................................
// updating values in a deleted row should fail
deleteRandom();
final XRowUpdate rowUpdated = UnoRuntime.queryInterface( XRowUpdate.class, m_resultSet );
@ -721,7 +721,7 @@ public class RowSet extends TestCase
assertTrue("updating values in a deleted row should not succeed", caughtException);
}
// --------------------------------------------------------------------------------------------------------
/** checks whether deletions on the main RowSet properly interfere (or don't interfere) with the movement
* on a clone of the RowSet
*/
@ -737,7 +737,7 @@ public class RowSet extends TestCase
positionRandom();
// .....................................................................................................
// move the clone to the same record as the RowSet, and delete this record
cloneRowLocate.moveToBookmark(m_rowLocate.getBookmark());
final int clonePosition = clone.getRow();
@ -746,19 +746,19 @@ public class RowSet extends TestCase
assertTrue("clone doesn't know that its current row has been deleted via the RowSet", clone.rowDeleted());
assertTrue("clone's position changed somehow during deletion", clonePosition == clone.getRow());
// .....................................................................................................
// move the row set away from the deleted record. This should still not touch the state of the clone
m_resultSet.previous();
assertTrue("clone doesn't know (anymore) that its current row has been deleted via the RowSet", clone.rowDeleted());
assertTrue("clone's position changed somehow during deletion and RowSet-movement", clonePosition == clone.getRow());
// .....................................................................................................
// move the clone away from the deleted record
clone.next();
assertTrue("clone still assumes that its row is deleted - but we already moved it", !clone.rowDeleted());
// .....................................................................................................
// check whether deleting the extremes (first / last) work
m_resultSet.first();
cloneRowLocate.moveToBookmark(m_rowLocate.getBookmark());
@ -776,7 +776,7 @@ public class RowSet extends TestCase
clone.previous();
assertTrue("deleting the first record left the clone in a strange state (after |next| + |previous|)", clone.isLast());
// .....................................................................................................
// check whether movements of the clone interfere with movements of the RowSet, if the latter is on a deleted row
final int positionBefore = positionRandom();
m_resultSetUpdate.deleteRow();
@ -790,7 +790,7 @@ public class RowSet extends TestCase
assertTrue("wrong absolute position after |deleteRow| and clone movement", m_resultSet.getRow() == positionBefore);
}
// --------------------------------------------------------------------------------------------------------
/** checks whether insertions on the main RowSet properly interfere (or don't interfere) with the movement
* on a clone of the RowSet
*/
@ -804,7 +804,7 @@ public class RowSet extends TestCase
final XResultSet clone = createClone();
final XRow cloneRow = UnoRuntime.queryInterface( XRow.class, clone );
// .....................................................................................................
// first check the basic scenario without the |moveToInsertRow| |moveToCurrentRow|, to ensure that
// really those are broken, if at all
m_resultSet.last();
@ -821,7 +821,7 @@ public class RowSet extends TestCase
testPosition(clone, cloneRow, 1, "mixed clone/rowset move: clone check");
testPosition(m_resultSet, m_row, MAX_TABLE_ROWS, "mixed clone/rowset move: rowset check");
// .....................................................................................................
// now the complete scenario
m_resultSet.last();
m_resultSetUpdate.moveToInsertRow();
@ -834,7 +834,7 @@ public class RowSet extends TestCase
testPosition(m_resultSet, m_row, 100, "mixed clone/rowset move/insertion: rowset check");
}
// --------------------------------------------------------------------------------------------------------
private void testTableParameters()
{
// for a row set simply based on a table, there should be not parameters at all
@ -850,7 +850,7 @@ public class RowSet extends TestCase
fail("testing the parameters of a table failed" + e.getMessage());
}
}
// --------------------------------------------------------------------------------------------------------
private void testParametersAfterNormalExecute()
{
@ -868,7 +868,7 @@ public class RowSet extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
private void verifyParameters(String[] _paramNames, String _context) throws com.sun.star.uno.Exception
{
final XIndexAccess params = m_paramsSupplier.getParameters();
@ -894,7 +894,7 @@ public class RowSet extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
private void testParametrizedQuery()
{
try
@ -914,7 +914,7 @@ public class RowSet extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
private void testParametersInteraction()
{
try
@ -952,7 +952,7 @@ public class RowSet extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
private void testParametersInFilter()
{
try
@ -977,7 +977,7 @@ public class RowSet extends TestCase
}
}
// --------------------------------------------------------------------------------------------------------
/** checks the XParametersSupplier functionality of a RowSet
*/
@Test

View File

@ -40,7 +40,7 @@ import java.lang.reflect.Method;
// ---------- junit imports -----------------
import org.junit.Test;
import static org.junit.Assert.*;
// ------------------------------------------
public class SingleSelectQueryComposer extends CRMBasedTestCase
{
@ -54,13 +54,13 @@ public class SingleSelectQueryComposer extends CRMBasedTestCase
+ " OR ( NOW( ) = {D '2010-01-01' } )";
private final static String INNERPRODUCTSQUERY = "products (inner)";
// --------------------------------------------------------------------------------------------------------
private void createQueries() throws Exception
{
m_database.getDatabase().getDataSource().createQuery(INNERPRODUCTSQUERY, "SELECT * FROM \"products\"");
}
// --------------------------------------------------------------------------------------------------------
@Override
protected void createTestCase()
{
@ -79,7 +79,7 @@ public class SingleSelectQueryComposer extends CRMBasedTestCase
}
}
// --------------------------------------------------------------------------------------------------------
private void checkAttributeAccess(String _attributeName, String _attributeValue)
{
System.out.println("setting " + _attributeName + " to " + _attributeValue);

View File

@ -37,28 +37,28 @@ import org.junit.AfterClass;
import org.junit.BeforeClass;
import org.openoffice.test.OfficeConnection;
import static org.junit.Assert.*;
// ------------------------------------------
public abstract class TestCase
{
// --------------------------------------------------------------------------------------------------------
protected final XComponentContext getComponentContext()
{
return connection.getComponentContext();
}
// --------------------------------------------------------------------------------------------------------
public void before() throws java.lang.Exception
{
}
// --------------------------------------------------------------------------------------------------------
public void after() throws java.lang.Exception
{
}
// --------------------------------------------------------------------------------------------------------
/** returns the URL of a temporary file which can be used during the test.
*
* The file will be deleted when the process exits
@ -74,7 +74,7 @@ public abstract class TestCase
return FileHelper.getOOoCompatibleFileURL( documentFile.toURI().toURL().toString() );
}
// --------------------------------------------------------------------------------------------------------
/**
* copies the file given by URL to a temporary file
* @return
@ -92,7 +92,7 @@ public abstract class TestCase
return FileHelper.getOOoCompatibleFileURL( targetURL );
}
// --------------------------------------------------------------------------------------------------------
protected final XModel loadDocument( final String _docURL ) throws Exception
{
final XComponentLoader loader = UnoRuntime.queryInterface( XComponentLoader.class,
@ -101,7 +101,7 @@ public abstract class TestCase
loader.loadComponentFromURL( _docURL, "_blank", 0, new PropertyValue[] {} ) );
}
// --------------------------------------------------------------------------------------------------------
/** invokes a given method on a given object, and assures a certain exception is caught
* @param _message
* is the message to print when the check fails
@ -198,7 +198,7 @@ public abstract class TestCase
_object, _methodName, _argClasses, _methodArgs, _expectedExceptionClass );
}
// --------------------------------------------------------------------------------------------------------
@SuppressWarnings("unchecked")
protected void assureException( Object _object, Class _unoInterfaceClass, String _methodName, Object[] _methodArgs,
Class _expectedExceptionClass )
@ -207,14 +207,14 @@ public abstract class TestCase
_methodArgs, _expectedExceptionClass );
}
// --------------------------------------------------------------------------------------------------------
protected XMultiServiceFactory getMSF()
{
final XMultiServiceFactory xMSF1 = UnoRuntime.queryInterface(XMultiServiceFactory.class, connection.getComponentContext().getServiceManager());
return xMSF1;
}
// --------------------------------------------------------------------------------------------------------
// setup and close connections
@BeforeClass
public static void setUpConnection() throws Exception
@ -222,7 +222,7 @@ public abstract class TestCase
connection.setUp();
}
// --------------------------------------------------------------------------------------------------------
@AfterClass
public static void tearDownConnection() throws InterruptedException, com.sun.star.uno.Exception
{

View File

@ -31,11 +31,11 @@ import connectivity.tools.CRMDatabase;
// ---------- junit imports -----------------
import org.junit.Test;
import static org.junit.Assert.*;
// ------------------------------------------
public class UISettings extends TestCase
{
// --------------------------------------------------------------------------------------------------------
/** verifies that aliases for inner queries work as expected
*/
@Test

View File

@ -454,9 +454,9 @@ namespace dbaccess
};
//************************************************************
// ORowSetClone
//************************************************************
class ORowSetClone : public comphelper::OBaseMutex
,public OSubComponent
,public ORowSetBase

View File

@ -28,9 +28,9 @@
#include <resultcolumn.hxx>
namespace dbaccess
{
//************************************************************
// ODataColumn
//************************************************************
class ODataColumn : public OResultColumn,
public ::com::sun::star::sdb::XColumn,
public ::com::sun::star::sdb::XColumnUpdate

View File

@ -25,9 +25,9 @@
#include <boost/optional.hpp>
namespace dbaccess
{
//************************************************************
// OResultColumn
//************************************************************
class OResultColumn : public OColumn,
public ::comphelper::OPropertyArrayUsageHelper < OResultColumn >
{

View File

@ -58,9 +58,9 @@ namespace dbaccess
typedef ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface> ONoWeakStatement;
//************************************************************
// OResultSet
//************************************************************
class OResultSet : public comphelper::OBaseMutex,
public OResultSetBase,
public ::cppu::OPropertySetHelper,

View File

@ -430,9 +430,9 @@ Reference< XResultSet > SAL_CALL OStatementBase::getGeneratedValues( ) throw (S
return Reference< XResultSet >();
}
//************************************************************
// OStatement
//************************************************************
OStatement::OStatement( const Reference< XConnection >& _xConn, const Reference< XInterface > & _xStatement )
:OStatementBase( _xConn, _xStatement )
,m_bAttemptedComposerCreation( false )

View File

@ -25,9 +25,9 @@
namespace dbaccess
{
//************************************************************
// OCallableStatement
//************************************************************
class OCallableStatement : public OPreparedStatement,
public ::com::sun::star::sdbc::XRow,
public ::com::sun::star::sdbc::XOutParameters

View File

@ -55,9 +55,9 @@
namespace dbaccess
{
//************************************************************
// OColumn
//************************************************************
typedef ::cppu::WeakComponentImplHelper2< ::com::sun::star::lang::XServiceInfo,
::com::sun::star::container::XNamed
> OColumnBase;

View File

@ -20,7 +20,7 @@
#ifndef _DBA_MISCRES_HRC_
#define _DBA_MISCRES_HRC_
//========================================================================
// string ids (relative to other resources, that's why not unique)
#define STR_MYSQL_ODBC 1
#define STR_MYSQL_JDBC 2

View File

@ -29,9 +29,9 @@
namespace dbaccess
{
//************************************************************
// OPreparedStatement
//************************************************************
class OPreparedStatement : public OStatementBase,
public ::com::sun::star::sdbc::XPreparedStatement,
public ::com::sun::star::sdbc::XParameters,

View File

@ -37,9 +37,9 @@
#include <cppuhelper/implbase3.hxx>
//************************************************************
// OStatementBase
//************************************************************
class OStatementBase : public comphelper::OBaseMutex,
public OSubComponent,
public ::cppu::OPropertySetHelper,
@ -129,9 +129,9 @@ protected:
using ::cppu::OPropertySetHelper::getFastPropertyValue;
};
//************************************************************
// OStatement
//************************************************************
typedef ::cppu::ImplHelper3 < ::com::sun::star::sdbc::XStatement
, ::com::sun::star::lang::XServiceInfo
, ::com::sun::star::sdbc::XBatchExecution

View File

@ -300,7 +300,7 @@ String RID_STR_UPDATE_FAILED
Text [ en-US ] = "Current row could not be updated.";
};
//-------------------------------------------------------------------------
String RID_STR_NO_INSERT_PRIVILEGE
{

View File

@ -22,37 +22,37 @@
#include <svl/solar.hrc>
//=====================================================================
//= bases
//=====================================================================
#define RID_DBMM_DIALOG_START RID_DBACCESS_START + 0
#define RID_DBMM_TAPPAGE_START RID_DBACCESS_START + 0
#define RID_DBMM_STRING_START RID_DBACCESS_START + 0
//=====================================================================
//= dialogs
//=====================================================================
#define DLG_MACRO_MIGRATION RID_DBMM_DIALOG_START + 0
//=====================================================================
//= error boxes
//=====================================================================
#define ERR_INVALID_BACKUP_LOCATION RID_DBMM_DIALOG_START + 0
//=====================================================================
//= tab pages
//=====================================================================
#define TP_PREPARE ( RID_DBMM_TAPPAGE_START + 0 )
#define TP_SAVE_DBDOC_AS ( RID_DBMM_TAPPAGE_START + 1 )
#define TP_MIGRATE ( RID_DBMM_TAPPAGE_START + 2 )
#define TP_SUMMARY ( RID_DBMM_TAPPAGE_START + 3 )
//=====================================================================
//= strings
//=====================================================================
#define STR_FORM ( RID_DBMM_STRING_START + 0 )
#define STR_REPORT ( RID_DBMM_STRING_START + 1 )

View File

@ -20,7 +20,7 @@
#include "dbmm_global.hrc"
#include "macromigration.hrc"
// -----------------------------------------------------------------------------
ModalDialog DLG_MACRO_MIGRATION
{
HelpID = "dbaccess:ModalDialog:DLG_MACRO_MIGRATION";
@ -52,9 +52,9 @@ ModalDialog DLG_MACRO_MIGRATION
};
};
//========================================================================
//= PreparationPage
//========================================================================
TabPage TP_PREPARE
{
@ -103,9 +103,9 @@ TabPage TP_PREPARE
};
};
//========================================================================
//= SaveDBDocPage
//========================================================================
TabPage TP_SAVE_DBDOC_AS
{
@ -180,9 +180,9 @@ TabPage TP_SAVE_DBDOC_AS
};
};
//========================================================================
//= ProgressPage
//========================================================================
TabPage TP_MIGRATE
{
@ -294,9 +294,9 @@ TabPage TP_MIGRATE
};
};
//========================================================================
//= ResultPage
//========================================================================
TabPage TP_SUMMARY
{

View File

@ -26,8 +26,8 @@ using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::lang;
using namespace ::com::sun::star::registry;
//***************************************************************************************
//
// registry functions
extern "C" void SAL_CALL createRegistryInfo_ODBFilter();
extern "C" void SAL_CALL createRegistryInfo_ODBFilterExport();
@ -37,7 +37,7 @@ extern "C" void SAL_CALL createRegistryInfo_DBContentLoader2();
extern "C" void SAL_CALL createRegistryInfo_DBTypeDetection();
extern "C" void SAL_CALL writeDBLoaderInfo2(void* pRegistryKey);
//***************************************************************************************
extern "C" void SAL_CALL createRegistryInfo_dbaxml()
{
static sal_Bool bInit = sal_False;

View File

@ -26,14 +26,14 @@
#undef STRINGCONSTANTS_INCLUDED_INDIRECT
#include "stringconstants.inc"
//============================================================
//= SQLSTATE
//============================================================
#define SQLSTATE_GENERAL "01000"
//============================================================
//= Properties
//============================================================
#define PROPERTY_APPLYFORMDESIGNMODE "ApplyFormDesignMode"
#define PROPERTY_IS_FORM "IsForm"
#define PROPERTY_PERSISTENT_PATH "PersistentPath"

View File

@ -26,9 +26,9 @@
#undef STRINGCONSTANTS_INCLUDED_INDIRECT
#include "stringconstants.inc"
//============================================================
//= URLs
//============================================================
#define URL_COMPONENT_QUERYDESIGN ".component:DB/QueryDesign"
#define URL_COMPONENT_VIEWDESIGN ".component:DB/ViewDesign"
#define URL_COMPONENT_TABLEDESIGN ".component:DB/TableDesign"
@ -38,23 +38,23 @@
#define URL_COMPONENT_APPLICATION ".component:DB/Application"
#define URL_COMPONENT_REPORTDESIGN ".component:DB/ReportDesign"
//============================================================
//= service names
//============================================================
#define SERVICE_SDB_DIRECTSQLDIALOG "org.openoffice.comp.dbu.DirectSqlDialog"
//============================================================
//= other DBU relevant strings
//============================================================
#define FRAME_NAME_QUERY_PREVIEW "QueryPreview"
#define SERVICE_CONTROLDEFAULT "com.sun.star.comp.dbu.OColumnControl"
#define PROPERTY_QUERYDESIGNVIEW "QueryDesignView"
#define PROPERTY_GRAPHICAL_DESIGN "GraphicalDesign"
#define PROPERTY_HELP_URL "HelpURL"
//============================================================
//= other DBU properties
//============================================================
#define PROPERTY_TRISTATE "TriState"
#define PROPERTY_ENABLEOUTERJOIN "EnableOuterJoinEscape"
#define PROPERTY_TABSTOP "TabStop"

View File

@ -24,9 +24,9 @@
#error "don't include this file directly! use dbastrings.hrc or dbustrings.hrc instead!"
#endif
//============================================================
//= property ids
//============================================================
#define PROPERTY_ID_TITLE 1
#define PROPERTY_ID_URL 2
#define PROPERTY_ID_INFO 4

View File

@ -18,9 +18,9 @@
// be included itself
//============================================================
//= property names
//============================================================
#define PROPERTY_URL "URL"
#define PROPERTY_INFO "Info"
#define PROPERTY_SETTINGS "Settings"
@ -175,9 +175,9 @@
#define PROPERTY_SINGLESELECTQUERYCOMPOSER "SingleSelectQueryComposer"
#define PROPERTY_CHANGE_NOTIFICATION_ENABLED "PropertyChangeNotificationEnabled"
//============================================================
//= service names
//============================================================
#define SERVICE_SDBC_RESULTSET "com.sun.star.sdbc.ResultSet"
#define SERVICE_SDBC_ROWSET "com.sun.star.sdbc.RowSet"
#define SERVICE_SDBC_STATEMENT "com.sun.star.sdbc.Statement"

View File

@ -172,9 +172,9 @@ namespace sdbtools
{
if ( ( _rName.indexOf( (sal_Unicode)34 ) >= 0 ) // "
|| ( _rName.indexOf( (sal_Unicode)39 ) >= 0 ) // '
|| ( _rName.indexOf( (sal_Unicode)96 ) >= 0 ) //
|| ( _rName.indexOf( (sal_Unicode)145 ) >= 0 ) //
|| ( _rName.indexOf( (sal_Unicode)146 ) >= 0 ) //
|| ( _rName.indexOf( (sal_Unicode)96 ) >= 0 )
|| ( _rName.indexOf( (sal_Unicode)145 ) >= 0 )
|| ( _rName.indexOf( (sal_Unicode)146 ) >= 0 )
|| ( _rName.indexOf( (sal_Unicode)180 ) >= 0 ) // removed unparsable chars
)
return ErrorCondition::DB_QUERY_NAME_WITH_QUOTES;

View File

@ -22,10 +22,10 @@
#include <svl/solar.hrc>
//------------------------------------------------------------------------------
#define RID_SDBT_STRINGS_START RID_DBACCESS_START
//------------------------------------------------------------------------------
//- String-IDs
#define STR_QUERY_AND_TABLE_DISTINCT_NAMES RID_SDBT_STRINGS_START + 0
#define STR_BASENAME_TABLE RID_SDBT_STRINGS_START + 1

View File

@ -90,6 +90,6 @@ String STR_ADD_TABLE_OR_QUERY
};
// -------------------------------------------------------------------------------------------------
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */

View File

@ -105,7 +105,7 @@
WordBreak = TRUE; \
};
// -------------------------------------------------------------------------------------------------
#define AUTO_BROWSECONTROLGROUP( AUTO_X, AUTO_Y, AUTOPAGE_X, AUTO_HID, AUTO_HID2) \
@ -143,7 +143,7 @@
Text[ en-US ] = "Create New"; \
};
// --------------------------------------------------------------------------------------------------
#define AUTO_NAMECONTROLGROUP(AUTO_Y, AUTO_HID) \
@ -163,7 +163,7 @@
Border = TRUE ; \
};
// --------------------------------------------------------------------------------------------------
#define AUTO_HOSTCONTROLGROUP(AUTO_Y, AUTO_HID) \
@ -183,7 +183,7 @@
Border = TRUE ; \
};
// --------------------------------------------------------------------------------------------------
#define AUTO_BASEDNCONTROLGROUP(AUTO_Y, AUTO_HID) \
@ -203,7 +203,7 @@
Border = TRUE ; \
}; \
// --------------------------------------------------------------------------------------------------
// MBA: the HID set in the FixText can't make any sense; in case this macro was called from within the
// AUTOHELP_JDBCCONTROLGROUP, the FixText would have got the same HID as an EditField from the
@ -233,7 +233,7 @@
Text[ en-US ] = "" ; \
};
//-------------------------------------------------------------------------
#define AUTO_CHARSET( AUTO_Y, AUTOPAGE_X ) \
FixedLine FL_DATACONVERT \
@ -259,7 +259,7 @@
CurPos = 0 ; \
}; \
// --------------------------------------------------------------------------------------------------
#define AUTO_SEPARATORCONTROLGROUP(AUTO_Y,AUTOPAGE_X) \
\
FixedText FT_AUTOEXTENSIONHEADER \
@ -432,14 +432,14 @@
};
// --------------------------------------------------------------------------------------------------
#define AUTO_HELP_BROWSECONTROLGROUP(AUTO_LINECOUNT, AUTO_HID, AUTO_HID2) \
AUTO_WIZARDHELPTEXT(AUTO_LINECOUNT) \
AUTO_BROWSECONTROLGROUP(START_X, INIT_Y + AUTO_LINECOUNT * FIXEDTEXT_HEIGHT + 2, WIZARD_PAGE_X, AUTO_HID, AUTO_HID2)
// --------------------------------------------------------------------------------------------------
#define AUTO_JDBCDRIVERCLASSGROUP(AUTO_Y, AUTO_HID, AUTO_HID2) \
\
@ -469,7 +469,7 @@
Text[ en-US ] = "Test class" ; \
};
// --------------------------------------------------------------------------------------------------
#define AUTO_SOCKETCONTROLGROUP(AUTO_Y) \
FixedText FT_SOCKET \
@ -497,7 +497,7 @@
AUTO_JDBCDRIVERCLASSGROUP(146, AUTO_HID4, AUTO_HID5)
// --------------------------------------------------------------------------------------------------
#endif

View File

@ -20,7 +20,7 @@
#ifndef DBAUI_CONNECTIONPAGE_HRC
#define DBAUI_CONNECTIONPAGE_HRC
//========================================================================
// control ids
#define FT_USERNAME 1

View File

@ -22,7 +22,7 @@
#include "ConnectionPage.hrc"
#include "AutoControls.hrc"
//.........................................................................
TabPage PAGE_CONNECTION
{
HelpID = "dbaccess:TabPage:PAGE_CONNECTION";

View File

@ -20,7 +20,7 @@
#ifndef _DBAUI_DBADMIN_HRC_
#define _DBAUI_DBADMIN_HRC_
//========================================================================
// control ids
// FREE

View File

@ -24,7 +24,7 @@
#include "browserids.hxx"
#include "admincontrols.hrc"
//-------------------------------------------------------------------------
#define AUTO_USECATALOG(AUTO_Y) \
CheckBox CB_USECATALOG \
@ -36,7 +36,7 @@
Text[ en-US ] = "Use catalog for file-based databases"; \
};
//-------------------------------------------------------------------------
#define AUTO_FIXEDLINE_CONNSETTINGS(AUTO_Y) \
FixedLine FL_SEPARATOR1 \
@ -76,7 +76,7 @@
Pos = MAP_APPFONT ( EDIT_X , AUTO_Y +UNRELATED_CONTROLS + FIXEDTEXT_HEIGHT ) ; \
Size = MAP_APPFONT ( 97 , EDIT_HEIGHT ) ; \
};
//-------------------------------------------------------------------------
ModalDialog DLG_DATABASE_TYPE_CHANGE
{
@ -93,7 +93,7 @@ ModalDialog DLG_DATABASE_TYPE_CHANGE
Text [ en-US ] = "Database properties" ;
};
//.........................................................................
TabPage PAGE_DBASE
{
@ -140,7 +140,7 @@ TabPage PAGE_DBASE
};
};
//.........................................................................
TabPage PAGE_ADO
{
@ -152,7 +152,7 @@ TabPage PAGE_ADO
AUTO_CHARSET(UNRELATED_CONTROLS,PAGE_X)
};
//.........................................................................
TabPage PAGE_ODBC
{
@ -188,7 +188,7 @@ TabPage PAGE_ODBC
AUTO_USECATALOG( 3*UNRELATED_CONTROLS + 4*FIXEDTEXT_HEIGHT + 2*RELATED_CONTROLS )
};
//.........................................................................
TabPage PAGE_MYSQL_ODBC
{
@ -324,7 +324,7 @@ TabPage PAGE_ORACLE_JDBC
AUTO_CHARSET( 5*UNRELATED_CONTROLS + RELATED_CONTROLS + 4*FIXEDTEXT_HEIGHT+ EDIT_HEIGHT, PAGE_X )
};
//.........................................................................
TabPage PAGE_LDAP
{
@ -399,7 +399,7 @@ TabPage PAGE_LDAP
};
//.........................................................................
TabPage PAGE_TEXT
{
@ -412,7 +412,7 @@ TabPage PAGE_TEXT
AUTO_SEPARATORCONTROLGROUP(UNRELATED_CONTROLS, PAGE_X)
};
//.........................................................................
TabPage PAGE_USERDRIVER
{
SVLook = TRUE ;

View File

@ -24,7 +24,7 @@
#include "toolbox.hrc"
#include "AutoControls.hrc"
//.........................................................................
String STR_ENTER_CONNECTION_PASSWORD
{

View File

@ -28,7 +28,7 @@
#define EDIT_X 101
// -----------------------------------------------------------------------------
ModalDialog DLG_DATABASE_WIZARD
{
OutputSize = TRUE ;

View File

@ -21,7 +21,7 @@
#include "dbu_dlg.hrc"
#include "sqlmessage.hrc"
//-------------------------------------------------------------------------
Image BMP_EXCEPTION_ERROR
{
ImageBitmap = Bitmap { File = "exerror.png"; };

View File

@ -22,7 +22,7 @@
#define MASKCOLOR MaskColor = Color { Red = 0xFFFF; Green = 0x0000; Blue = 0xFFFF; }
//-------------------------------------------------------------------------
#define IL_TOOL_2 \
\
IdList = {\
@ -75,10 +75,10 @@ Image IMG_TABLEFOLDER_TREE_L
MASKCOLOR;
};
//========================================================================
//= database object icons
//------------------------------------------------------------------------
// the whole database
Image DATABASE_TREE_ICON
@ -87,7 +87,7 @@ Image DATABASE_TREE_ICON
MaskColor = Color { Red = 0xff00 ; Green = 0x0000 ; Blue = 0xff00 ; };
};
//------------------------------------------------------------------------
// tables and table folders
Image TABLE_TREE_ICON
@ -102,7 +102,7 @@ Image TABLEFOLDER_TREE_ICON
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
//------------------------------------------------------------------------
// views
Image VIEW_TREE_ICON
@ -111,7 +111,7 @@ Image VIEW_TREE_ICON
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
//------------------------------------------------------------------------
// queries and query folders
Image QUERY_TREE_ICON
@ -126,7 +126,7 @@ Image QUERYFOLDER_TREE_ICON
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
//------------------------------------------------------------------------
// forms and form folders
Image FORM_TREE_ICON
@ -141,7 +141,7 @@ Image FORMFOLDER_TREE_ICON
MASKCOLOR;
};
//------------------------------------------------------------------------
// reports and report folders
Image REPORT_TREE_ICON

View File

@ -130,7 +130,7 @@ namespace dbaui
static ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >
SAL_CALL Create(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >&);
//
virtual void Load(const ::com::sun::star::uno::Reference< ::com::sun::star::io::XObjectInputStream>& _rxIn);
virtual void Save(const ::com::sun::star::uno::Reference< ::com::sun::star::io::XObjectOutputStream>& _rxOut);

View File

@ -73,7 +73,7 @@
#error Resource-Id Ueberlauf in #file, #line
#endif
//========================================================================
// dialog ids
#define DLG_SQLEXCEPTIONCHAIN RID_DIALOG_START + 3
@ -93,7 +93,7 @@
#define DLG_DATABASE_TYPE_CHANGE RID_DIALOG_START + 28
#define DLG_DATABASE_WIZARD RID_DIALOG_START + 29
#define DLG_TEXT_CONNECTION_SETTINGS RID_DIALOG_START + 31
//========================================================================
// tab pages
// FREE
@ -136,14 +136,14 @@
#define PAGE_DBWIZARD_USERDEFINED RID_PAGE_START + 56
#define PAGE_DBWIZARD_MYSQL_NATIVE RID_PAGE_START + 57
//========================================================================
// error boxes
#define ERR_QRY_CRITERIA_ON_ASTERISK RID_ERRORBOX_START + 2
#define ERR_QRY_ORDERBY_ON_ASTERISK RID_ERRORBOX_START + 3
#define ERR_NEED_INDEX_FIELDS RID_ERRORBOX_START + 8
//========================================================================
// query boxes
#define QUERY_BRW_DELETE_ROWS RID_QUERYBOX_START + 0
@ -161,7 +161,7 @@
#define QUERY_USERADMIN_DELETE_USER RID_QUERYBOX_START + 12
#define TABLE_DESIGN_ALL_ROWS_DELETED RID_QUERYBOX_START + 13
//========================================================================
// images
#define TABLE_TREE_ICON RID_IMAGE_START + 0
@ -189,13 +189,13 @@
#define FORMFOLDER_TREE_ICON RID_IMAGE_START + 55
//========================================================================
// image lists
#define IMG_JOINS RID_IMAGELIST_START + 0
#define IMG_INDEX_DLG_SC RID_IMAGELIST_START + 1
#define IMG_INDEX_DLG_LC RID_IMAGELIST_START + 3
//========================================================================
// menus
#define RID_SBA_GRID_COLCTXMENU RID_MENU_START + 2
@ -214,13 +214,13 @@
//========================================================================
// controls
#define RID_DB_TAB_EDITOR RID_CONTROL_START + 0
#define RID_MYSQL_NATIVE_SETTINGS RID_CONTROL_START + 1
//========================================================================
// strings
#define STR_TBL_TITLE RID_STR_GEN_START
#define STR_ERROR_DURING_CREATION RID_STR_GEN_START + 1
@ -270,13 +270,13 @@
#define STR_TITLE_RENAME RID_STR_GEN_START + 45
#define STR_TITLE_PASTE_AS RID_STR_GEN_START + 46
//========================================================================
// untyped resources
#define RSC_CHARSETS RID_UNTYPED_START + 2
#define RSC_QUERY_OBJECT_TYPE RID_UNTYPED_START + 4
//========================================================================
// various
#define PB_FORMAT RID_MISC_START + 0

View File

@ -32,7 +32,7 @@ namespace dbaui
class ORowUpdateHelper : public IUpdateHelper
{
::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XRowUpdate > m_xRowUpdate;
::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XResultSetUpdate > m_xResultSetUpdate; //
::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XResultSetUpdate > m_xResultSetUpdate;
public:
ORowUpdateHelper(const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XRowSet>& _xRowSet)
:m_xRowUpdate(_xRowSet,::com::sun::star::uno::UNO_QUERY)

View File

@ -98,9 +98,9 @@ ModalDialog WIZ_RTFCOPYTABLE
};
//==================================================================
// TAB_WIZ_COLUMN_SELECT
//==================================================================
TabPage TAB_WIZ_COLUMN_SELECT
{
SVLook = TRUE ;
@ -225,9 +225,9 @@ TabPage TAB_WIZ_COLUMN_SELECT
};
};
//==================================================================
// TAB_WIZ_TYPE_SELECT
//==================================================================
TabPage TAB_WIZ_TYPE_SELECT
{
SVLook = TRUE ;
@ -312,9 +312,9 @@ Menu RID_SBA_RTF_PKEYPOPUP
};
};
//==================================================================
// TAB_WIZ_NAME_MATCHING
//==================================================================
TabPage TAB_WIZ_NAME_MATCHING
{
HelpID = "dbaccess:TabPage:TAB_WIZ_NAME_MATCHING";

View File

@ -26,8 +26,8 @@ using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::lang;
using namespace ::com::sun::star::registry;
//***************************************************************************************
//
// registry functions
extern "C" void SAL_CALL createRegistryInfo_OTableFilterDialog();
extern "C" void SAL_CALL createRegistryInfo_ODataSourcePropertyDialog();
@ -55,7 +55,7 @@ extern "C" void SAL_CALL createRegistryInfo_CopyTableWizard();
extern "C" void SAL_CALL createRegistryInfo_OTextConnectionSettingsDialog();
extern "C" void SAL_CALL createRegistryInfo_LimitBoxController();
//***************************************************************************************
extern "C" void SAL_CALL createRegistryInfo_DBU()
{
static sal_Bool bInit = sal_False;