DrawLinks

open class DrawLinks<P : Position2D<out P>?> : AbstractEffect<P>

Simple effect that draws a black line for each it.unibo.alchemist.model.interfaces.Node in a it.unibo.alchemist.model.interfaces.Neighborhood.

It's possible to set the size of the dots.

Parameters

<P>

the position type

Constructors

Link copied to clipboard
open fun DrawLinks()
Empty constructor.
Link copied to clipboard
open fun DrawLinks(name: String)
Default constructor.

Functions

Link copied to clipboard
@Contract(value = "null, null -> true; null, !null -> false; !null, null -> false")
open fun <T : AbstractEffect<out Any>?> checkBasicProperties(@Nullable anEffect: T, @Nullable otherEffect: Any): Boolean
The method compares two Effects to check basic properties of visibility, name and class.
Link copied to clipboard
@Contract(value = "null, !null -> false")
open fun <T, P : Property<T>?> checkEqualsProperties(@Nullable prop1: P, @Nullable prop2: P): Boolean
The method is useful to implement comparisons of properties in equals method.
Link copied to clipboard
abstract fun <T> computeDrawCommands(environment: Environment<T, P>): Queue<DrawCommand<P>>
open fun <T> computeDrawCommands(environment: Environment<T, P>): Queue<DrawCommand<P>>
Computes a queue of commands to Draw something.
Link copied to clipboard
open fun equals(obj: Any): Boolean
Link copied to clipboard
open fun getSize(): Double
Gets the value of the property sizeProperty.
Link copied to clipboard
open fun hashCode(): Int
Link copied to clipboard
fun isVisible(): Boolean
Gets the visibility of the effect.
Link copied to clipboard
open fun setSize(size: Double)
Sets the value of the property sizeProperty.
Link copied to clipboard
open fun sizeProperty(): DoubleProperty
The size of the dots representing each it.unibo.alchemist.model.interfaces.Node in the Environment specified when drawing.

Properties

Link copied to clipboard
open var name: String
Link copied to clipboard
private open var visibility: Boolean