From c902f9098b331302aaa1baac77d1575db624a132 Mon Sep 17 00:00:00 2001 From: John Firebaugh Date: Tue, 26 Apr 2016 16:39:56 -0700 Subject: [core] Rationalize naming for style-related code --- src/mbgl/style/layers/line_layer.cpp | 165 +++++++++++++++++++++++++++++++++++ 1 file changed, 165 insertions(+) create mode 100644 src/mbgl/style/layers/line_layer.cpp (limited to 'src/mbgl/style/layers/line_layer.cpp') diff --git a/src/mbgl/style/layers/line_layer.cpp b/src/mbgl/style/layers/line_layer.cpp new file mode 100644 index 0000000000..abe326a672 --- /dev/null +++ b/src/mbgl/style/layers/line_layer.cpp @@ -0,0 +1,165 @@ +// This file is generated. Edit scripts/generate-style-code.js, then run `make style-code`. + +#include +#include + +namespace mbgl { +namespace style { + +LineLayer::LineLayer(const std::string& layerID) + : Layer(Type::Line, std::make_unique()) + , impl(static_cast(baseImpl.get())) { + impl->id = layerID; +} + +LineLayer::LineLayer(const Impl& other) + : Layer(Type::Line, std::make_unique(other)) + , impl(static_cast(baseImpl.get())) { +} + +LineLayer::~LineLayer() = default; + +std::unique_ptr LineLayer::Impl::clone() const { + return std::make_unique(*this); +} + +// Source + +void LineLayer::setSource(const std::string& sourceID, const std::string& sourceLayer) { + impl->source = sourceID; + impl->sourceLayer = sourceLayer; +} + +const std::string& LineLayer::getSourceID() const { + return impl->source; +} + +const std::string& LineLayer::getSourceLayer() const { + return impl->sourceLayer; +} + +// Filter + +void LineLayer::setFilter(const Filter& filter) { + impl->filter = filter; +} + +const Filter& LineLayer::getFilter() const { + return impl->filter; +} + +// Layout properties + +PropertyValue LineLayer::getLineCap() const { + return impl->layout.lineCap.get(); +} + +void LineLayer::setLineCap(PropertyValue value) { + impl->layout.lineCap.set(value); +} +PropertyValue LineLayer::getLineJoin() const { + return impl->layout.lineJoin.get(); +} + +void LineLayer::setLineJoin(PropertyValue value) { + impl->layout.lineJoin.set(value); +} +PropertyValue LineLayer::getLineMiterLimit() const { + return impl->layout.lineMiterLimit.get(); +} + +void LineLayer::setLineMiterLimit(PropertyValue value) { + impl->layout.lineMiterLimit.set(value); +} +PropertyValue LineLayer::getLineRoundLimit() const { + return impl->layout.lineRoundLimit.get(); +} + +void LineLayer::setLineRoundLimit(PropertyValue value) { + impl->layout.lineRoundLimit.set(value); +} + +// Paint properties + +PropertyValue LineLayer::getLineOpacity() const { + return impl->paint.lineOpacity.get(); +} + +void LineLayer::setLineOpacity(PropertyValue value) { + impl->paint.lineOpacity.set(value); +} + +PropertyValue LineLayer::getLineColor() const { + return impl->paint.lineColor.get(); +} + +void LineLayer::setLineColor(PropertyValue value) { + impl->paint.lineColor.set(value); +} + +PropertyValue> LineLayer::getLineTranslate() const { + return impl->paint.lineTranslate.get(); +} + +void LineLayer::setLineTranslate(PropertyValue> value) { + impl->paint.lineTranslate.set(value); +} + +PropertyValue LineLayer::getLineTranslateAnchor() const { + return impl->paint.lineTranslateAnchor.get(); +} + +void LineLayer::setLineTranslateAnchor(PropertyValue value) { + impl->paint.lineTranslateAnchor.set(value); +} + +PropertyValue LineLayer::getLineWidth() const { + return impl->paint.lineWidth.get(); +} + +void LineLayer::setLineWidth(PropertyValue value) { + impl->paint.lineWidth.set(value); +} + +PropertyValue LineLayer::getLineGapWidth() const { + return impl->paint.lineGapWidth.get(); +} + +void LineLayer::setLineGapWidth(PropertyValue value) { + impl->paint.lineGapWidth.set(value); +} + +PropertyValue LineLayer::getLineOffset() const { + return impl->paint.lineOffset.get(); +} + +void LineLayer::setLineOffset(PropertyValue value) { + impl->paint.lineOffset.set(value); +} + +PropertyValue LineLayer::getLineBlur() const { + return impl->paint.lineBlur.get(); +} + +void LineLayer::setLineBlur(PropertyValue value) { + impl->paint.lineBlur.set(value); +} + +PropertyValue> LineLayer::getLineDasharray() const { + return impl->paint.lineDasharray.get(); +} + +void LineLayer::setLineDasharray(PropertyValue> value) { + impl->paint.lineDasharray.set(value); +} + +PropertyValue LineLayer::getLinePattern() const { + return impl->paint.linePattern.get(); +} + +void LineLayer::setLinePattern(PropertyValue value) { + impl->paint.linePattern.set(value); +} + +} // namespace style +} // namespace mbgl -- cgit v1.2.1