diff options
author | Artur Signell <artur@vaadin.com> | 2014-03-19 16:30:23 +0200 |
---|---|---|
committer | Artur Signell <artur@vaadin.com> | 2014-03-19 16:32:32 +0200 |
commit | 227a937af1d844f7372a5a3071c1e204e25a49c0 (patch) | |
tree | 9428bffbb09cfadb9fd3ec932652a96fc52b76f4 | |
parent | 23891f2519410d174e9e923e2ca5842c78c8e757 (diff) | |
download | vaadin-framework-227a937af1d844f7372a5a3071c1e204e25a49c0.tar.gz vaadin-framework-227a937af1d844f7372a5a3071c1e204e25a49c0.zip |
Format project files according to conventions
Change-Id: I2522698237eb2a21c0896605bed8e73a82795c97
10 files changed, 48 insertions, 30 deletions
diff --git a/client/src/com/vaadin/client/ComponentLocator.java b/client/src/com/vaadin/client/ComponentLocator.java index ef7ccc3b65..f30528c0c0 100644 --- a/client/src/com/vaadin/client/ComponentLocator.java +++ b/client/src/com/vaadin/client/ComponentLocator.java @@ -22,11 +22,13 @@ package com.vaadin.client; * @since 5.4 * @deprecated Moved to com.vaadin.client.componentlocator.ComponentLocator */ -public class ComponentLocator extends com.vaadin.client.componentlocator.ComponentLocator { +public class ComponentLocator extends + com.vaadin.client.componentlocator.ComponentLocator { /** * Construct a ComponentLocator for the given ApplicationConnection. * - * @param client ApplicationConnection instance for the application. + * @param client + * ApplicationConnection instance for the application. */ public ComponentLocator(ApplicationConnection client) { super(client); diff --git a/client/src/com/vaadin/client/ui/VScrollTable.java b/client/src/com/vaadin/client/ui/VScrollTable.java index 1b0dd646d1..54aca5381f 100644 --- a/client/src/com/vaadin/client/ui/VScrollTable.java +++ b/client/src/com/vaadin/client/ui/VScrollTable.java @@ -7828,10 +7828,16 @@ public class VScrollTable extends FlowPanel implements HasWidgets, private static final String SUBPART_FOOTER = "footer"; private static final String SUBPART_ROW = "row"; private static final String SUBPART_COL = "col"; - /** Matches header[ix] - used for extracting the index of the targeted header cell */ + /** + * Matches header[ix] - used for extracting the index of the targeted header + * cell + */ private static final RegExp SUBPART_HEADER_REGEXP = RegExp .compile(SUBPART_HEADER + "\\[(\\d+)\\]"); - /** Matches footer[ix] - used for extracting the index of the targeted footer cell */ + /** + * Matches footer[ix] - used for extracting the index of the targeted footer + * cell + */ private static final RegExp SUBPART_FOOTER_REGEXP = RegExp .compile(SUBPART_FOOTER + "\\[(\\d+)\\]"); /** Matches row[ix] - used for extracting the index of the targeted row */ @@ -7839,7 +7845,8 @@ public class VScrollTable extends FlowPanel implements HasWidgets, + "\\[(\\d+)]"); /** Matches col[ix] - used for extracting the index of the targeted column */ private static final RegExp SUBPART_ROW_COL_REGEXP = RegExp - .compile(SUBPART_ROW + "\\[(\\d+)\\]/" + SUBPART_COL + "\\[(\\d+)\\]"); + .compile(SUBPART_ROW + "\\[(\\d+)\\]/" + SUBPART_COL + + "\\[(\\d+)\\]"); @Override public Element getSubPartElement(String subPart) { diff --git a/client/src/com/vaadin/client/ui/menubar/MenuBarConnector.java b/client/src/com/vaadin/client/ui/menubar/MenuBarConnector.java index 9ce418c358..0df413c1c3 100644 --- a/client/src/com/vaadin/client/ui/menubar/MenuBarConnector.java +++ b/client/src/com/vaadin/client/ui/menubar/MenuBarConnector.java @@ -81,7 +81,8 @@ public class MenuBarConnector extends AbstractComponentConnector implements + Util.escapeAttribute(client .translateVaadinUri(moreItemUIDL .getStringAttribute("icon"))) - + "\" class=\"" + ImageIcon.CLASSNAME + "\" alt=\"\" />"); + + "\" class=\"" + ImageIcon.CLASSNAME + + "\" alt=\"\" />"); } String moreItemText = moreItemUIDL.getStringAttribute("text"); diff --git a/server/src/com/vaadin/data/util/AbstractInMemoryContainer.java b/server/src/com/vaadin/data/util/AbstractInMemoryContainer.java index 9a7922b928..cae9f30fc9 100644 --- a/server/src/com/vaadin/data/util/AbstractInMemoryContainer.java +++ b/server/src/com/vaadin/data/util/AbstractInMemoryContainer.java @@ -148,8 +148,8 @@ public abstract class AbstractInMemoryContainer<ITEMIDTYPE, PROPERTYIDCLASS, ITE } } - private static abstract class BaseItemAddOrRemoveEvent extends - EventObject implements Serializable { + private static abstract class BaseItemAddOrRemoveEvent extends EventObject + implements Serializable { protected Object itemId; protected int index; protected int count; @@ -188,9 +188,8 @@ public abstract class AbstractInMemoryContainer<ITEMIDTYPE, PROPERTYIDCLASS, ITE * of added items. * </p> */ - protected static class BaseItemAddEvent extends - BaseItemAddOrRemoveEvent implements - Container.Indexed.ItemAddEvent { + protected static class BaseItemAddEvent extends BaseItemAddOrRemoveEvent + implements Container.Indexed.ItemAddEvent { public BaseItemAddEvent(Container source, Object itemId, int index, int count) { @@ -212,12 +211,11 @@ public abstract class AbstractInMemoryContainer<ITEMIDTYPE, PROPERTYIDCLASS, ITE * number of removed items. * </p> */ - protected static class BaseItemRemoveEvent extends - BaseItemAddOrRemoveEvent implements - Container.Indexed.ItemRemoveEvent { + protected static class BaseItemRemoveEvent extends BaseItemAddOrRemoveEvent + implements Container.Indexed.ItemRemoveEvent { - public BaseItemRemoveEvent(Container source, Object itemId, - int index, int count) { + public BaseItemRemoveEvent(Container source, Object itemId, int index, + int count) { super(source, itemId, index, count); } @@ -1003,8 +1001,8 @@ public abstract class AbstractInMemoryContainer<ITEMIDTYPE, PROPERTYIDCLASS, ITE */ protected void fireItemsAdded(int firstPosition, ITEMIDTYPE firstItemId, int numberOfItems) { - BaseItemAddEvent addEvent = new BaseItemAddEvent(this, - firstItemId, firstPosition, numberOfItems); + BaseItemAddEvent addEvent = new BaseItemAddEvent(this, firstItemId, + firstPosition, numberOfItems); fireItemSetChange(addEvent); } diff --git a/server/src/com/vaadin/server/communication/UidlWriter.java b/server/src/com/vaadin/server/communication/UidlWriter.java index b46fbbf58a..6c23da629e 100644 --- a/server/src/com/vaadin/server/communication/UidlWriter.java +++ b/server/src/com/vaadin/server/communication/UidlWriter.java @@ -99,8 +99,8 @@ public class UidlWriter implements Serializable { uiConnectorTracker.setWritingResponse(true); try { - writer.write("\"" + ApplicationConstants.SERVER_SYNC_ID - + "\": " + uiConnectorTracker.getCurrentSyncId() + ", "); + writer.write("\"" + ApplicationConstants.SERVER_SYNC_ID + "\": " + + uiConnectorTracker.getCurrentSyncId() + ", "); writer.write("\"changes\" : "); diff --git a/server/tests/src/com/vaadin/tests/data/converter/TestDateToSqlDateConverter.java b/server/tests/src/com/vaadin/tests/data/converter/TestDateToSqlDateConverter.java index 685404ded6..d591d10e18 100644 --- a/server/tests/src/com/vaadin/tests/data/converter/TestDateToSqlDateConverter.java +++ b/server/tests/src/com/vaadin/tests/data/converter/TestDateToSqlDateConverter.java @@ -19,7 +19,7 @@ public class TestDateToSqlDateConverter extends TestCase { public void testValueConversion() { Date testDate = new Date(100, 0, 1); long time = testDate.getTime(); - assertEquals(testDate, converter.convertToModel(new java.sql.Date(time), - java.sql.Date.class, Locale.ENGLISH)); + assertEquals(testDate, converter.convertToModel( + new java.sql.Date(time), java.sql.Date.class, Locale.ENGLISH)); } } diff --git a/server/tests/src/com/vaadin/tests/server/validation/TestBeanValidation.java b/server/tests/src/com/vaadin/tests/server/validation/TestBeanValidation.java index 1d1a3c297e..832ae14950 100644 --- a/server/tests/src/com/vaadin/tests/server/validation/TestBeanValidation.java +++ b/server/tests/src/com/vaadin/tests/server/validation/TestBeanValidation.java @@ -84,6 +84,7 @@ public class TestBeanValidation { Assert.assertEquals(2, causes.length); } + public void testBeanValidationNotAddedTwice() { // See ticket #11045 BeanFieldGroup<BeanToValidate> fieldGroup = new BeanFieldGroup<BeanToValidate>( diff --git a/uitest/src/com/vaadin/tests/components/calendar/TestHideTimeAndSeparator.java b/uitest/src/com/vaadin/tests/components/calendar/TestHideTimeAndSeparator.java index b8b55048f9..60e8720d44 100644 --- a/uitest/src/com/vaadin/tests/components/calendar/TestHideTimeAndSeparator.java +++ b/uitest/src/com/vaadin/tests/components/calendar/TestHideTimeAndSeparator.java @@ -21,7 +21,8 @@ public class TestHideTimeAndSeparator extends AbstractTestUI { private final String caption; private final boolean hideTime; - public GenericEvent(Date start, Date end, String caption, boolean hideTime) { + public GenericEvent(Date start, Date end, String caption, + boolean hideTime) { this.start = start; this.end = end; this.caption = caption; @@ -60,10 +61,16 @@ public class TestHideTimeAndSeparator extends AbstractTestUI { } - CalendarEvent shortEventHidden = new GenericEvent(makeDate(2013, 1, 2, 8, 0), makeDate(2013, 1, 2, 8, 30), "Short event", true); - CalendarEvent longEventHidden = new GenericEvent(makeDate(2013, 1, 2, 10, 0), makeDate(2013, 1, 2, 12, 0), "Long event", true); - CalendarEvent shortEvent = new GenericEvent(makeDate(2013, 1, 3, 8, 0), makeDate(2013, 1, 3, 8, 30), "Short event", false); - CalendarEvent longEvent = new GenericEvent(makeDate(2013, 1, 3, 10, 0), makeDate(2013, 1, 3, 12, 0), "Long event", false); + CalendarEvent shortEventHidden = new GenericEvent( + makeDate(2013, 1, 2, 8, 0), makeDate(2013, 1, 2, 8, 30), + "Short event", true); + CalendarEvent longEventHidden = new GenericEvent( + makeDate(2013, 1, 2, 10, 0), makeDate(2013, 1, 2, 12, 0), + "Long event", true); + CalendarEvent shortEvent = new GenericEvent(makeDate(2013, 1, 3, 8, 0), + makeDate(2013, 1, 3, 8, 30), "Short event", false); + CalendarEvent longEvent = new GenericEvent(makeDate(2013, 1, 3, 10, 0), + makeDate(2013, 1, 3, 12, 0), "Long event", false); @Override protected void setup(VaadinRequest request) { @@ -100,6 +107,7 @@ public class TestHideTimeAndSeparator extends AbstractTestUI { juc.set(year, month, day, hour, minute); return juc.getTime(); } + private Date makeDate(int year, int month, int day) { java.util.Calendar juc = java.util.Calendar.getInstance(); juc.set(year, month, day); diff --git a/uitest/src/com/vaadin/tests/push/TrackMessageSizeUITest.java b/uitest/src/com/vaadin/tests/push/TrackMessageSizeUITest.java index f904675b5e..2fc868d4ed 100644 --- a/uitest/src/com/vaadin/tests/push/TrackMessageSizeUITest.java +++ b/uitest/src/com/vaadin/tests/push/TrackMessageSizeUITest.java @@ -24,7 +24,7 @@ public class TrackMessageSizeUITest extends MultiBrowserTest { @Test public void runTests() { openTestURL(); - Assert.assertEquals("1. All tests run", - vaadinElementById("Log_row_0").getText()); + Assert.assertEquals("1. All tests run", vaadinElementById("Log_row_0") + .getText()); } }
\ No newline at end of file diff --git a/uitest/src/com/vaadin/tests/tb3/PrivateTB3Configuration.java b/uitest/src/com/vaadin/tests/tb3/PrivateTB3Configuration.java index 400a2fe429..a00ff7ab4d 100644 --- a/uitest/src/com/vaadin/tests/tb3/PrivateTB3Configuration.java +++ b/uitest/src/com/vaadin/tests/tb3/PrivateTB3Configuration.java @@ -125,7 +125,8 @@ public abstract class PrivateTB3Configuration extends ScreenshotTB3Test { || nwInterface.isVirtual()) { continue; } - Enumeration<InetAddress> addresses = nwInterface.getInetAddresses(); + Enumeration<InetAddress> addresses = nwInterface + .getInetAddresses(); while (addresses.hasMoreElements()) { InetAddress address = addresses.nextElement(); if (address.isLoopbackAddress()) { |