[Geoserver-devel] Make GeoServer nodes identifiable from the GUI

That would work for me. However perhaps if we want to give full control in terms of layout perhaps we should do something like this.

GeoServerNodeInfo {
String getId();
WebMarkupContainer render(MarkupContainer parent);
}

···

And then with a subclass that creates a single element with a css stye applied. Whether that is from a template, an option map, or a single getCssStyle() method becomes an implementation detail.

On Thu, Mar 13, 2014 at 9:41 AM, Andrea Aime <andrea.aime@anonymised.com> wrote:

Justin Deoliveira
Vice President, Engineering | Boundless
jdeolive@anonymised.com
@j_deolive

And of course I forgot to complete this sentence… I wanted to give implementors of GeoServerNodeInfo
the ability to control the styling fully. However if we apply the approach below, that would
work with getOptions as a map too.

Cheers
Andrea

==
Meet us at GEO Business 2014! in London! Visit http://goo.gl/fES3aK
for more information.

Ing. Andrea Aime

@geowolf
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549

http://www.geo-solutions.it
http://twitter.com/geosolutions_it


There was actually a reason, the style that sits behind the identifier element is build
from this template:

position:absolute; top:12px; left:12px; right:28px; width:auto; background:$background; padding: 1px; border: 1px solid #0076a1; color:$color; font-weight:bold

Hmmm… how about using the same terminology as the system properties:

interface GeoServerNodeInfo {

String getId();
Map<String,String> getOptions();

}

However, getOptions could just return all of the above as a map (with the placeholders replaced)
and the style attribute be built from it. I guess we can also have each of the elements templatable
and allow new elements to be inserted, that would make the above a “default”, so that if
for example you want to have italic you could add font-style:italic to the system variable.

On Thu, Mar 13, 2014 at 4:49 PM, Justin Deoliveira <
jdeolive@anonymised.com> wrote:

That would work for me. However perhaps if we want to give full control in
terms of layout perhaps we should do something like this.

GeoServerNodeInfo {
  String getId();
  WebMarkupContainer render(MarkupContainer parent);
}

And then with a subclass that creates a single element with a css stye
applied. Whether that is from a template, an option map, or a single
getCssStyle() method becomes an implementation detail.

Sure, this works for me

Cheers
Andrea

--

Meet us at GEO Business 2014! in London! Visit http://goo.gl/fES3aK
for more information.

Ing. Andrea Aime
@geowolf
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

-------------------------------------------------------