Class LuaPropertiesHelper

java.lang.Object
games.stendhal.server.core.scripting.lua.LuaPropertiesHelper

public class LuaPropertiesHelper extends Object
Exposes Java system properties to Lua.
  • Method Details

    • get

      public static LuaPropertiesHelper get()
      Retrieves the static instance.
      Returns:
      Static PropertiesHelper instance.
    • getValue

      public String getValue(String p)
      Retrievies the value of a property.
      Parameters:
      p - The property of which the value should be returned.
      Returns:
      Value of the property or null if not set.
    • enabled

      public boolean enabled(String p)
      Checks if a property is set.
      Parameters:
      p - The property string to check.
      Returns:
      true if the property is not null.
    • equals

      public boolean equals(String p, String v)
      Compares a property value to a string.
      Parameters:
      p - The property string to check.
      v - The value to check the property against.
      Returns:
      true if the property value is equal to v.