Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

RowStyleGenerator.java 1.3KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. /*
  2. * Copyright 2000-2016 Vaadin Ltd.
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License"); you may not
  5. * use this file except in compliance with the License. You may obtain a copy of
  6. * the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
  12. * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
  13. * License for the specific language governing permissions and limitations under
  14. * the License.
  15. */
  16. package com.vaadin.client.widget.grid;
  17. import java.io.Serializable;
  18. /**
  19. * Callback interface for generating custom style names for data rows.
  20. *
  21. * @author Vaadin Ltd
  22. * @param <T>
  23. * the row type of the target grid
  24. * @see com.vaadin.client.widgets.Grid#setRowStyleGenerator(RowStyleGenerator)
  25. * Grid#setRowStyleGenerator(RowStyleGenerator)
  26. * @since 7.4
  27. */
  28. public interface RowStyleGenerator<T> extends Serializable {
  29. /**
  30. * Called by Grid to generate a style name for a row.
  31. *
  32. * @param rowReference
  33. * The row to generate a style for
  34. * @return the style name to add to this row, or {@code null} to not set any
  35. * style
  36. */
  37. public abstract String getStyle(RowReference<T> rowReference);
  38. }