source: josm/trunk/src/org/openstreetmap/josm/tools/Property.java@ 6977

Last change on this file since 6977 was 6223, checked in by Don-vip, 11 years ago

Sonar - fix various violations

  • Property svn:eol-style set to native
File size: 695 bytes
Line 
1// License: GPL. For details, see LICENSE file.
2package org.openstreetmap.josm.tools;
3
4/**
5 * Small interface to define a property with both read and write access.
6 * @param <O> Object type
7 * @param <P> Property type
8 */
9public interface Property<O, P> {
10
11 /**
12 * Get the value of the property.
13 * @param obj the object, from that the property is derived
14 * @return the value of the property for the object obj
15 */
16 public P get(O obj);
17
18 /**
19 * Set the value of the property for the object.
20 * @param obj the object for that the property should be set
21 * @param value the value the property is set to
22 */
23 public void set(O obj, P value);
24}
Note: See TracBrowser for help on using the repository browser.