Search in sources :

Example 1 with LengthFunction

use of org.structr.core.function.LengthFunction in project structr by structr.

the class CoreModule method onLoad.

@Override
public void onLoad(final LicenseManager licenseManager) {
    final boolean licensed = licenseManager == null || licenseManager.isEdition(LicenseManager.Basic);
    // Basic Edition
    Functions.put(licensed, LicenseManager.Basic, "error", new ErrorFunction());
    Functions.put(licensed, LicenseManager.Basic, "config", new ConfigFunction());
    Functions.put(licensed, LicenseManager.Basic, "changelog", new ChangelogFunction());
    Functions.put(licensed, LicenseManager.Basic, "serverlog", new ServerLogFunction());
    Functions.put(licensed, LicenseManager.Basic, "grant", new GrantFunction());
    Functions.put(licensed, LicenseManager.Basic, "revoke", new RevokeFunction());
    Functions.put(licensed, LicenseManager.Basic, "is_allowed", new IsAllowedFunction());
    Functions.put(licensed, LicenseManager.Basic, "add_to_group", new AddToGroupFunction());
    Functions.put(licensed, LicenseManager.Basic, "remove_from_group", new RemoveFromGroupFunction());
    Functions.put(licensed, LicenseManager.Basic, "is_in_group", new IsInGroupFunction());
    Functions.put(licensed, LicenseManager.Basic, "localize", new LocalizeFunction());
    Functions.put(licensed, LicenseManager.Basic, "call", new CallFunction());
    Functions.put(licensed, LicenseManager.Basic, "call_privileged", new CallPrivilegedFunction());
    Functions.put(licensed, LicenseManager.Basic, "exec", new ExecFunction());
    Functions.put(licensed, LicenseManager.Basic, "exec_binary", new ExecBinaryFunction());
    Functions.put(licensed, LicenseManager.Basic, "unlock_readonly_properties_once", new UnlockReadonlyPropertiesFunction());
    Functions.put(licensed, LicenseManager.Basic, "unlock_system_properties_once", new UnlockSystemPropertiesFunction());
    Functions.put(licensed, LicenseManager.Basic, "set_privileged", new SetPrivilegedFunction());
    Functions.put(licensed, LicenseManager.Basic, "find_privileged", new PrivilegedFindFunction());
    Functions.put(licensed, LicenseManager.Basic, "read", new ReadFunction());
    Functions.put(licensed, LicenseManager.Basic, "write", new WriteFunction());
    Functions.put(licensed, LicenseManager.Basic, "append", new AppendFunction());
    Functions.put(licensed, LicenseManager.Basic, "xml", new XmlFunction());
    Functions.put(licensed, LicenseManager.Basic, "xpath", new XPathFunction());
    Functions.put(licensed, LicenseManager.Basic, "geocode", new GeocodeFunction());
    Functions.put(licensed, LicenseManager.Basic, "instantiate", new InstantiateFunction());
    Functions.put(licensed, LicenseManager.Basic, "property_info", new PropertyInfoFunction());
    Functions.put(licensed, LicenseManager.Basic, "type_info", new TypeInfoFunction());
    Functions.put(licensed, LicenseManager.Basic, "enum_info", new EnumInfoFunction());
    Functions.put(licensed, LicenseManager.Basic, "disable_notifications", new DisableNotificationsFunction());
    Functions.put(licensed, LicenseManager.Basic, "enable_notifications", new EnableNotificationsFunction());
    Functions.put(licensed, LicenseManager.Basic, "r", new RInterpreterFunction());
    Functions.put(licensed, LicenseManager.Basic, "evaluate_script", new EvaluateScriptFunction());
    Functions.put(licensed, LicenseManager.Basic, "ancestor_types", new AncestorTypesFunction());
    Functions.put(licensed, LicenseManager.Basic, "inheriting_types", new InheritingTypesFunction());
    Functions.put(licensed, LicenseManager.Basic, "template", new TemplateFunction());
    Functions.put(licensed, LicenseManager.Basic, "jdbc", new JdbcFunction());
    // Community Edition
    Functions.put(true, LicenseManager.Community, "cypher", new CypherFunction());
    Functions.put(true, LicenseManager.Community, "md5", new MD5Function());
    Functions.put(true, LicenseManager.Community, "upper", new UpperFunction());
    Functions.put(true, LicenseManager.Community, "lower", new LowerFunction());
    Functions.put(true, LicenseManager.Community, "join", new JoinFunction());
    Functions.put(true, LicenseManager.Community, "concat", new ConcatFunction());
    Functions.put(true, LicenseManager.Community, "split", new SplitFunction());
    Functions.put(true, LicenseManager.Community, "split_regex", new SplitRegexFunction());
    Functions.put(true, LicenseManager.Community, "abbr", new AbbrFunction());
    Functions.put(true, LicenseManager.Community, "capitalize", new CapitalizeFunction());
    Functions.put(true, LicenseManager.Community, "titleize", new TitleizeFunction());
    Functions.put(true, LicenseManager.Community, "num", new NumFunction());
    Functions.put(true, LicenseManager.Community, "int", new IntFunction());
    Functions.put(true, LicenseManager.Community, "random", new RandomFunction());
    Functions.put(true, LicenseManager.Community, "rint", new RintFunction());
    Functions.put(true, LicenseManager.Community, "index_of", new IndexOfFunction());
    Functions.put(true, LicenseManager.Community, "contains", new ContainsFunction());
    Functions.put(true, LicenseManager.Community, "copy_permissions", new CopyPermissionsFunction());
    Functions.put(true, LicenseManager.Community, "substring", new SubstringFunction());
    Functions.put(true, LicenseManager.Community, "length", new LengthFunction());
    Functions.put(true, LicenseManager.Community, "replace", new ReplaceFunction());
    Functions.put(true, LicenseManager.Community, "trim", new TrimFunction());
    Functions.put(true, LicenseManager.Community, "clean", new CleanFunction());
    Functions.put(true, LicenseManager.Community, "coalesce", new CoalesceFunction());
    Functions.put(true, LicenseManager.Community, "urlencode", new UrlEncodeFunction());
    Functions.put(true, LicenseManager.Community, "escape_javascript", new EscapeJavascriptFunction());
    Functions.put(true, LicenseManager.Community, "escape_json", new EscapeJsonFunction());
    Functions.put(true, LicenseManager.Community, "empty", new EmptyFunction());
    Functions.put(true, LicenseManager.Community, "equal", new EqualFunction());
    Functions.put(true, LicenseManager.Community, "eq", new EqualFunction());
    Functions.put(true, LicenseManager.Community, "add", new AddFunction());
    Functions.put(true, LicenseManager.Community, "double_sum", new DoubleSumFunction());
    Functions.put(true, LicenseManager.Community, "int_sum", new IntSumFunction());
    Functions.put(true, LicenseManager.Community, "is_collection", new IsCollectionFunction());
    Functions.put(true, LicenseManager.Community, "is_entity", new IsEntityFunction());
    Functions.put(true, LicenseManager.Community, "extract", new ExtractFunction());
    Functions.put(true, LicenseManager.Community, "merge", new MergeFunction());
    Functions.put(true, LicenseManager.Community, "merge_unique", new MergeUniqueFunction());
    Functions.put(true, LicenseManager.Community, "complement", new ComplementFunction());
    Functions.put(true, LicenseManager.Community, "unwind", new UnwindFunction());
    Functions.put(true, LicenseManager.Community, "sort", new SortFunction());
    Functions.put(true, LicenseManager.Community, "lt", new LtFunction());
    Functions.put(true, LicenseManager.Community, "gt", new GtFunction());
    Functions.put(true, LicenseManager.Community, "lte", new LteFunction());
    Functions.put(true, LicenseManager.Community, "gte", new GteFunction());
    Functions.put(true, LicenseManager.Community, "subt", new SubtFunction());
    Functions.put(true, LicenseManager.Community, "mult", new MultFunction());
    Functions.put(true, LicenseManager.Community, "quot", new QuotFunction());
    Functions.put(true, LicenseManager.Community, "div", new DivFunction());
    Functions.put(true, LicenseManager.Community, "mod", new ModFunction());
    Functions.put(true, LicenseManager.Community, "floor", new FloorFunction());
    Functions.put(true, LicenseManager.Community, "ceil", new CeilFunction());
    Functions.put(true, LicenseManager.Community, "round", new RoundFunction());
    Functions.put(true, LicenseManager.Community, "max", new MaxFunction());
    Functions.put(true, LicenseManager.Community, "min", new MinFunction());
    Functions.put(true, LicenseManager.Community, "date_format", new DateFormatFunction());
    Functions.put(true, LicenseManager.Community, "parse_date", new ParseDateFunction());
    Functions.put(true, LicenseManager.Community, "to_date", new ToDateFunction());
    Functions.put(true, LicenseManager.Community, "number_format", new NumberFormatFunction());
    Functions.put(true, LicenseManager.Community, "parse_number", new ParseNumberFunction());
    Functions.put(true, LicenseManager.Community, "not", new NotFunction());
    Functions.put(true, LicenseManager.Community, "and", new AndFunction());
    Functions.put(true, LicenseManager.Community, "or", new OrFunction());
    Functions.put(true, LicenseManager.Community, "get", new GetFunction());
    Functions.put(true, LicenseManager.Community, "get_or_null", new GetOrNullFunction());
    Functions.put(true, LicenseManager.Community, "size", new SizeFunction());
    Functions.put(true, LicenseManager.Community, "first", new FirstFunction());
    Functions.put(true, LicenseManager.Community, "last", new LastFunction());
    Functions.put(true, LicenseManager.Community, "nth", new NthFunction());
    Functions.put(true, LicenseManager.Community, "get_counter", new GetCounterFunction());
    Functions.put(true, LicenseManager.Community, "inc_counter", new IncCounterFunction());
    Functions.put(true, LicenseManager.Community, "reset_counter", new ResetCounterFunction());
    Functions.put(true, LicenseManager.Community, "merge_properties", new MergePropertiesFunction());
    Functions.put(true, LicenseManager.Community, "keys", new KeysFunction());
    Functions.put(true, LicenseManager.Community, "values", new ValuesFunction());
    Functions.put(true, LicenseManager.Community, "timer", new TimerFunction());
    Functions.put(true, LicenseManager.Community, "str_replace", new StrReplaceFunction());
    Functions.put(true, LicenseManager.Community, "search", new SearchFunction());
    Functions.put(true, LicenseManager.Community, "incoming", new IncomingFunction());
    Functions.put(true, LicenseManager.Community, "outgoing", new OutgoingFunction());
    Functions.put(true, LicenseManager.Community, "has_relationship", new HasRelationshipFunction());
    Functions.put(true, LicenseManager.Community, "has_outgoing_relationship", new HasOutgoingRelationshipFunction());
    Functions.put(true, LicenseManager.Community, "has_incoming_relationship", new HasIncomingRelationshipFunction());
    Functions.put(true, LicenseManager.Community, "get_relationships", new GetRelationshipsFunction());
    Functions.put(true, LicenseManager.Community, "get_outgoing_relationships", new GetOutgoingRelationshipsFunction());
    Functions.put(true, LicenseManager.Community, "get_incoming_relationships", new GetIncomingRelationshipsFunction());
    Functions.put(true, LicenseManager.Community, "retrieve", new RetrieveFunction());
    Functions.put(true, LicenseManager.Community, "store", new StoreFunction());
    Functions.put(true, LicenseManager.Community, "print", new PrintFunction());
    Functions.put(true, LicenseManager.Community, "log", new LogFunction());
    Functions.put(true, LicenseManager.Community, "find", new FindFunction());
    Functions.put(true, LicenseManager.Community, "get_or_create", new GetOrCreateFunction());
    Functions.put(true, LicenseManager.Community, "find_relationship", new FindRelationshipFunction());
    Functions.put(true, LicenseManager.Community, "starts_with", new StartsWithFunction());
    Functions.put(true, LicenseManager.Community, "ends_with", new EndsWithFunction());
    Functions.put(true, LicenseManager.Community, "base64encode", new Base64EncodeFunction());
    Functions.put(true, LicenseManager.Community, "base64decode", new Base64DecodeFunction());
    // ----- BEGIN functions with side effects -----
    Functions.put(true, LicenseManager.Community, "set", new SetFunction());
    Functions.put(true, LicenseManager.Community, "create", new CreateFunction());
    Functions.put(true, LicenseManager.Community, "delete", new DeleteFunction());
    Functions.put(true, LicenseManager.Community, "create_relationship", new CreateRelationshipFunction());
}
Also used : HasRelationshipFunction(org.structr.core.function.HasRelationshipFunction) LowerFunction(org.structr.core.function.LowerFunction) IsCollectionFunction(org.structr.core.function.IsCollectionFunction) XmlFunction(org.structr.core.function.XmlFunction) CypherFunction(org.structr.core.function.CypherFunction) ResetCounterFunction(org.structr.core.function.ResetCounterFunction) PrivilegedFindFunction(org.structr.core.function.PrivilegedFindFunction) FindFunction(org.structr.core.function.FindFunction) ExecFunction(org.structr.core.function.ExecFunction) GetIncomingRelationshipsFunction(org.structr.core.function.GetIncomingRelationshipsFunction) InheritingTypesFunction(org.structr.core.function.InheritingTypesFunction) SplitFunction(org.structr.core.function.SplitFunction) GetOutgoingRelationshipsFunction(org.structr.core.function.GetOutgoingRelationshipsFunction) EqualFunction(org.structr.core.function.EqualFunction) PrintFunction(org.structr.core.function.PrintFunction) OutgoingFunction(org.structr.core.function.OutgoingFunction) SortFunction(org.structr.core.function.SortFunction) ServerLogFunction(org.structr.core.function.ServerLogFunction) IncomingFunction(org.structr.core.function.IncomingFunction) NotFunction(org.structr.core.function.NotFunction) GetOrCreateFunction(org.structr.core.function.GetOrCreateFunction) MergeFunction(org.structr.core.function.MergeFunction) EnableNotificationsFunction(org.structr.core.function.EnableNotificationsFunction) GrantFunction(org.structr.core.function.GrantFunction) LastFunction(org.structr.core.function.LastFunction) StrReplaceFunction(org.structr.core.function.StrReplaceFunction) AndFunction(org.structr.core.function.AndFunction) AddToGroupFunction(org.structr.core.function.AddToGroupFunction) SubtFunction(org.structr.core.function.SubtFunction) AbbrFunction(org.structr.core.function.AbbrFunction) GteFunction(org.structr.core.function.GteFunction) MergeUniqueFunction(org.structr.core.function.MergeUniqueFunction) GetRelationshipsFunction(org.structr.core.function.GetRelationshipsFunction) IntFunction(org.structr.core.function.IntFunction) EscapeJavascriptFunction(org.structr.core.function.EscapeJavascriptFunction) ParseNumberFunction(org.structr.core.function.ParseNumberFunction) RintFunction(org.structr.core.function.RintFunction) FirstFunction(org.structr.core.function.FirstFunction) AppendFunction(org.structr.core.function.AppendFunction) AncestorTypesFunction(org.structr.core.function.AncestorTypesFunction) NumberFormatFunction(org.structr.core.function.NumberFormatFunction) RevokeFunction(org.structr.core.function.RevokeFunction) ToDateFunction(org.structr.core.function.ToDateFunction) GetCounterFunction(org.structr.core.function.GetCounterFunction) CopyPermissionsFunction(org.structr.core.function.CopyPermissionsFunction) ValuesFunction(org.structr.core.function.ValuesFunction) EscapeJsonFunction(org.structr.core.function.EscapeJsonFunction) Base64DecodeFunction(org.structr.core.function.Base64DecodeFunction) UnlockSystemPropertiesFunction(org.structr.core.function.UnlockSystemPropertiesFunction) IsAllowedFunction(org.structr.core.function.IsAllowedFunction) IndexOfFunction(org.structr.core.function.IndexOfFunction) MinFunction(org.structr.core.function.MinFunction) GetOrNullFunction(org.structr.core.function.GetOrNullFunction) MultFunction(org.structr.core.function.MultFunction) WriteFunction(org.structr.core.function.WriteFunction) LtFunction(org.structr.core.function.LtFunction) RandomFunction(org.structr.core.function.RandomFunction) CallFunction(org.structr.core.function.CallFunction) ModFunction(org.structr.core.function.ModFunction) IncCounterFunction(org.structr.core.function.IncCounterFunction) CreateRelationshipFunction(org.structr.core.function.CreateRelationshipFunction) ErrorFunction(org.structr.core.function.ErrorFunction) RetrieveFunction(org.structr.core.function.RetrieveFunction) CapitalizeFunction(org.structr.core.function.CapitalizeFunction) CallPrivilegedFunction(org.structr.core.function.CallPrivilegedFunction) TypeInfoFunction(org.structr.core.function.TypeInfoFunction) SetFunction(org.structr.core.function.SetFunction) ParseDateFunction(org.structr.core.function.ParseDateFunction) ServerLogFunction(org.structr.core.function.ServerLogFunction) LogFunction(org.structr.core.function.LogFunction) UnlockReadonlyPropertiesFunction(org.structr.core.function.UnlockReadonlyPropertiesFunction) ReadFunction(org.structr.core.function.ReadFunction) JoinFunction(org.structr.core.function.JoinFunction) GeocodeFunction(org.structr.core.function.GeocodeFunction) EndsWithFunction(org.structr.core.function.EndsWithFunction) ConfigFunction(org.structr.core.function.ConfigFunction) ExecBinaryFunction(org.structr.core.function.ExecBinaryFunction) JdbcFunction(org.structr.core.function.JdbcFunction) DoubleSumFunction(org.structr.core.function.DoubleSumFunction) PropertyInfoFunction(org.structr.core.function.PropertyInfoFunction) GetOrCreateFunction(org.structr.core.function.GetOrCreateFunction) CreateFunction(org.structr.core.function.CreateFunction) SplitRegexFunction(org.structr.core.function.SplitRegexFunction) UrlEncodeFunction(org.structr.core.function.UrlEncodeFunction) ConcatFunction(org.structr.core.function.ConcatFunction) FloorFunction(org.structr.core.function.FloorFunction) GtFunction(org.structr.core.function.GtFunction) ChangelogFunction(org.structr.core.function.ChangelogFunction) ExtractFunction(org.structr.core.function.ExtractFunction) SizeFunction(org.structr.core.function.SizeFunction) IsEntityFunction(org.structr.core.function.IsEntityFunction) UpperFunction(org.structr.core.function.UpperFunction) QuotFunction(org.structr.core.function.QuotFunction) RoundFunction(org.structr.core.function.RoundFunction) SetPrivilegedFunction(org.structr.core.function.SetPrivilegedFunction) EnumInfoFunction(org.structr.core.function.EnumInfoFunction) TemplateFunction(org.structr.core.function.TemplateFunction) Base64EncodeFunction(org.structr.core.function.Base64EncodeFunction) InstantiateFunction(org.structr.core.function.InstantiateFunction) IsInGroupFunction(org.structr.core.function.IsInGroupFunction) TrimFunction(org.structr.core.function.TrimFunction) OrFunction(org.structr.core.function.OrFunction) ContainsFunction(org.structr.core.function.ContainsFunction) StoreFunction(org.structr.core.function.StoreFunction) TitleizeFunction(org.structr.core.function.TitleizeFunction) CoalesceFunction(org.structr.core.function.CoalesceFunction) GetFunction(org.structr.core.function.GetFunction) HasIncomingRelationshipFunction(org.structr.core.function.HasIncomingRelationshipFunction) MergePropertiesFunction(org.structr.core.function.MergePropertiesFunction) StrReplaceFunction(org.structr.core.function.StrReplaceFunction) ReplaceFunction(org.structr.core.function.ReplaceFunction) TimerFunction(org.structr.core.function.TimerFunction) StartsWithFunction(org.structr.core.function.StartsWithFunction) RInterpreterFunction(org.structr.core.function.RInterpreterFunction) SubstringFunction(org.structr.core.function.SubstringFunction) NumFunction(org.structr.core.function.NumFunction) MD5Function(org.structr.core.function.MD5Function) NthFunction(org.structr.core.function.NthFunction) FindRelationshipFunction(org.structr.core.function.FindRelationshipFunction) LengthFunction(org.structr.core.function.LengthFunction) SearchFunction(org.structr.core.function.SearchFunction) AddFunction(org.structr.core.function.AddFunction) RemoveFromGroupFunction(org.structr.core.function.RemoveFromGroupFunction) LteFunction(org.structr.core.function.LteFunction) EvaluateScriptFunction(org.structr.core.function.EvaluateScriptFunction) LocalizeFunction(org.structr.core.function.LocalizeFunction) XPathFunction(org.structr.core.function.XPathFunction) MaxFunction(org.structr.core.function.MaxFunction) KeysFunction(org.structr.core.function.KeysFunction) DateFormatFunction(org.structr.core.function.DateFormatFunction) PrivilegedFindFunction(org.structr.core.function.PrivilegedFindFunction) HasOutgoingRelationshipFunction(org.structr.core.function.HasOutgoingRelationshipFunction) EmptyFunction(org.structr.core.function.EmptyFunction) ComplementFunction(org.structr.core.function.ComplementFunction) DisableNotificationsFunction(org.structr.core.function.DisableNotificationsFunction) IntSumFunction(org.structr.core.function.IntSumFunction) DivFunction(org.structr.core.function.DivFunction) DeleteFunction(org.structr.core.function.DeleteFunction) UnwindFunction(org.structr.core.function.UnwindFunction) CleanFunction(org.structr.core.function.CleanFunction) CeilFunction(org.structr.core.function.CeilFunction)

Aggregations

AbbrFunction (org.structr.core.function.AbbrFunction)1 AddFunction (org.structr.core.function.AddFunction)1 AddToGroupFunction (org.structr.core.function.AddToGroupFunction)1 AncestorTypesFunction (org.structr.core.function.AncestorTypesFunction)1 AndFunction (org.structr.core.function.AndFunction)1 AppendFunction (org.structr.core.function.AppendFunction)1 Base64DecodeFunction (org.structr.core.function.Base64DecodeFunction)1 Base64EncodeFunction (org.structr.core.function.Base64EncodeFunction)1 CallFunction (org.structr.core.function.CallFunction)1 CallPrivilegedFunction (org.structr.core.function.CallPrivilegedFunction)1 CapitalizeFunction (org.structr.core.function.CapitalizeFunction)1 CeilFunction (org.structr.core.function.CeilFunction)1 ChangelogFunction (org.structr.core.function.ChangelogFunction)1 CleanFunction (org.structr.core.function.CleanFunction)1 CoalesceFunction (org.structr.core.function.CoalesceFunction)1 ComplementFunction (org.structr.core.function.ComplementFunction)1 ConcatFunction (org.structr.core.function.ConcatFunction)1 ConfigFunction (org.structr.core.function.ConfigFunction)1 ContainsFunction (org.structr.core.function.ContainsFunction)1 CopyPermissionsFunction (org.structr.core.function.CopyPermissionsFunction)1