LineSymbolizer ls = sb.createLineSymbolizer();
ls.getStroke().setWidth(sb.getFilterFactory().property("myAttribute"));
FeatureTypeStyle fts = sb.createFeatureTypeStyle(sb.createPolygonSymbolizer());
style.featureTypeStyles().add(fts);
fts.rules().get(0).symbolizers().add(ls);
fts.rules().get(0).symbolizers().add(sb.createLineSymbolizer());
checkSingleSymbolizer(style, ls);
}
private void checkSingleSymbolizer(Style style, LineSymbolizer ls) {