// This file is generated. Edit scripts/generate-style-code.js, then run `make style-code`. #include #include #include namespace mbgl { namespace style { LineLayer::LineLayer(const std::string& layerID, const std::string& sourceID) : Layer(makeMutable(LayerType::Line, layerID, sourceID)) { } LineLayer::LineLayer(Immutable impl_) : Layer(std::move(impl_)) { } LineLayer::~LineLayer() = default; const LineLayer::Impl& LineLayer::impl() const { return static_cast(*baseImpl); } Mutable LineLayer::mutableImpl() const { return makeMutable(impl()); } std::unique_ptr LineLayer::cloneRef(const std::string& id_) const { auto impl_ = mutableImpl(); impl_->id = id_; impl_->paint = LinePaintProperties::Transitionable(); return std::make_unique(std::move(impl_)); } void LineLayer::Impl::stringifyLayout(rapidjson::Writer& writer) const { layout.stringify(writer); } // Source const std::string& LineLayer::getSourceID() const { return impl().source; } void LineLayer::setSourceLayer(const std::string& sourceLayer) { auto impl_ = mutableImpl(); impl_->sourceLayer = sourceLayer; baseImpl = std::move(impl_); } const std::string& LineLayer::getSourceLayer() const { return impl().sourceLayer; } // Filter void LineLayer::setFilter(const Filter& filter) { auto impl_ = mutableImpl(); impl_->filter = filter; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } const Filter& LineLayer::getFilter() const { return impl().filter; } // Visibility void LineLayer::setVisibility(VisibilityType value) { if (value == getVisibility()) return; auto impl_ = mutableImpl(); impl_->visibility = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } // Zoom range void LineLayer::setMinZoom(float minZoom) { auto impl_ = mutableImpl(); impl_->minZoom = minZoom; baseImpl = std::move(impl_); } void LineLayer::setMaxZoom(float maxZoom) { auto impl_ = mutableImpl(); impl_->maxZoom = maxZoom; baseImpl = std::move(impl_); } // Layout properties PropertyValue LineLayer::getDefaultLineCap() { return LineCap::defaultValue(); } PropertyValue LineLayer::getLineCap() const { return impl().layout.get(); } void LineLayer::setLineCap(PropertyValue value) { if (value == getLineCap()) return; auto impl_ = mutableImpl(); impl_->layout.get() = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } DataDrivenPropertyValue LineLayer::getDefaultLineJoin() { return LineJoin::defaultValue(); } DataDrivenPropertyValue LineLayer::getLineJoin() const { return impl().layout.get(); } void LineLayer::setLineJoin(DataDrivenPropertyValue value) { if (value == getLineJoin()) return; auto impl_ = mutableImpl(); impl_->layout.get() = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } PropertyValue LineLayer::getDefaultLineMiterLimit() { return LineMiterLimit::defaultValue(); } PropertyValue LineLayer::getLineMiterLimit() const { return impl().layout.get(); } void LineLayer::setLineMiterLimit(PropertyValue value) { if (value == getLineMiterLimit()) return; auto impl_ = mutableImpl(); impl_->layout.get() = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } PropertyValue LineLayer::getDefaultLineRoundLimit() { return LineRoundLimit::defaultValue(); } PropertyValue LineLayer::getLineRoundLimit() const { return impl().layout.get(); } void LineLayer::setLineRoundLimit(PropertyValue value) { if (value == getLineRoundLimit()) return; auto impl_ = mutableImpl(); impl_->layout.get() = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } // Paint properties DataDrivenPropertyValue LineLayer::getDefaultLineOpacity() { return { 1 }; } DataDrivenPropertyValue LineLayer::getLineOpacity() const { return impl().paint.template get().value; } void LineLayer::setLineOpacity(DataDrivenPropertyValue value) { if (value == getLineOpacity()) return; auto impl_ = mutableImpl(); impl_->paint.template get().value = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } void LineLayer::setLineOpacityTransition(const TransitionOptions& options) { auto impl_ = mutableImpl(); impl_->paint.template get().options = options; baseImpl = std::move(impl_); } TransitionOptions LineLayer::getLineOpacityTransition() const { return impl().paint.template get().options; } DataDrivenPropertyValue LineLayer::getDefaultLineColor() { return { Color::black() }; } DataDrivenPropertyValue LineLayer::getLineColor() const { return impl().paint.template get().value; } void LineLayer::setLineColor(DataDrivenPropertyValue value) { if (value == getLineColor()) return; auto impl_ = mutableImpl(); impl_->paint.template get().value = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } void LineLayer::setLineColorTransition(const TransitionOptions& options) { auto impl_ = mutableImpl(); impl_->paint.template get().options = options; baseImpl = std::move(impl_); } TransitionOptions LineLayer::getLineColorTransition() const { return impl().paint.template get().options; } PropertyValue> LineLayer::getDefaultLineTranslate() { return { {{ 0, 0 }} }; } PropertyValue> LineLayer::getLineTranslate() const { return impl().paint.template get().value; } void LineLayer::setLineTranslate(PropertyValue> value) { if (value == getLineTranslate()) return; auto impl_ = mutableImpl(); impl_->paint.template get().value = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } void LineLayer::setLineTranslateTransition(const TransitionOptions& options) { auto impl_ = mutableImpl(); impl_->paint.template get().options = options; baseImpl = std::move(impl_); } TransitionOptions LineLayer::getLineTranslateTransition() const { return impl().paint.template get().options; } PropertyValue LineLayer::getDefaultLineTranslateAnchor() { return { TranslateAnchorType::Map }; } PropertyValue LineLayer::getLineTranslateAnchor() const { return impl().paint.template get().value; } void LineLayer::setLineTranslateAnchor(PropertyValue value) { if (value == getLineTranslateAnchor()) return; auto impl_ = mutableImpl(); impl_->paint.template get().value = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } void LineLayer::setLineTranslateAnchorTransition(const TransitionOptions& options) { auto impl_ = mutableImpl(); impl_->paint.template get().options = options; baseImpl = std::move(impl_); } TransitionOptions LineLayer::getLineTranslateAnchorTransition() const { return impl().paint.template get().options; } DataDrivenPropertyValue LineLayer::getDefaultLineWidth() { return { 1 }; } DataDrivenPropertyValue LineLayer::getLineWidth() const { return impl().paint.template get().value; } void LineLayer::setLineWidth(DataDrivenPropertyValue value) { if (value == getLineWidth()) return; auto impl_ = mutableImpl(); impl_->paint.template get().value = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } void LineLayer::setLineWidthTransition(const TransitionOptions& options) { auto impl_ = mutableImpl(); impl_->paint.template get().options = options; baseImpl = std::move(impl_); } TransitionOptions LineLayer::getLineWidthTransition() const { return impl().paint.template get().options; } DataDrivenPropertyValue LineLayer::getDefaultLineGapWidth() { return { 0 }; } DataDrivenPropertyValue LineLayer::getLineGapWidth() const { return impl().paint.template get().value; } void LineLayer::setLineGapWidth(DataDrivenPropertyValue value) { if (value == getLineGapWidth()) return; auto impl_ = mutableImpl(); impl_->paint.template get().value = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } void LineLayer::setLineGapWidthTransition(const TransitionOptions& options) { auto impl_ = mutableImpl(); impl_->paint.template get().options = options; baseImpl = std::move(impl_); } TransitionOptions LineLayer::getLineGapWidthTransition() const { return impl().paint.template get().options; } DataDrivenPropertyValue LineLayer::getDefaultLineOffset() { return { 0 }; } DataDrivenPropertyValue LineLayer::getLineOffset() const { return impl().paint.template get().value; } void LineLayer::setLineOffset(DataDrivenPropertyValue value) { if (value == getLineOffset()) return; auto impl_ = mutableImpl(); impl_->paint.template get().value = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } void LineLayer::setLineOffsetTransition(const TransitionOptions& options) { auto impl_ = mutableImpl(); impl_->paint.template get().options = options; baseImpl = std::move(impl_); } TransitionOptions LineLayer::getLineOffsetTransition() const { return impl().paint.template get().options; } DataDrivenPropertyValue LineLayer::getDefaultLineBlur() { return { 0 }; } DataDrivenPropertyValue LineLayer::getLineBlur() const { return impl().paint.template get().value; } void LineLayer::setLineBlur(DataDrivenPropertyValue value) { if (value == getLineBlur()) return; auto impl_ = mutableImpl(); impl_->paint.template get().value = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } void LineLayer::setLineBlurTransition(const TransitionOptions& options) { auto impl_ = mutableImpl(); impl_->paint.template get().options = options; baseImpl = std::move(impl_); } TransitionOptions LineLayer::getLineBlurTransition() const { return impl().paint.template get().options; } PropertyValue> LineLayer::getDefaultLineDasharray() { return { { } }; } PropertyValue> LineLayer::getLineDasharray() const { return impl().paint.template get().value; } void LineLayer::setLineDasharray(PropertyValue> value) { if (value == getLineDasharray()) return; auto impl_ = mutableImpl(); impl_->paint.template get().value = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } void LineLayer::setLineDasharrayTransition(const TransitionOptions& options) { auto impl_ = mutableImpl(); impl_->paint.template get().options = options; baseImpl = std::move(impl_); } TransitionOptions LineLayer::getLineDasharrayTransition() const { return impl().paint.template get().options; } PropertyValue LineLayer::getDefaultLinePattern() { return { "" }; } PropertyValue LineLayer::getLinePattern() const { return impl().paint.template get().value; } void LineLayer::setLinePattern(PropertyValue value) { if (value == getLinePattern()) return; auto impl_ = mutableImpl(); impl_->paint.template get().value = value; baseImpl = std::move(impl_); observer->onLayerChanged(*this); } void LineLayer::setLinePatternTransition(const TransitionOptions& options) { auto impl_ = mutableImpl(); impl_->paint.template get().options = options; baseImpl = std::move(impl_); } TransitionOptions LineLayer::getLinePatternTransition() const { return impl().paint.template get().options; } } // namespace style } // namespace mbgl