Skip to content

Commit

Permalink
Add GetHandlerSets call, in handler factory.
Browse files Browse the repository at this point in the history
  • Loading branch information
Kevin Jump committed Jan 22, 2020
1 parent 1972c1e commit a44137a
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions uSync8.BackOffice/SyncHandlers/SyncHandlerFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,20 @@ public ISyncExtendedHandler GetHandlerByTypeName(string typeName)
=> syncHandlers.ExtendedHandlers
.FirstOrDefault(x => x.TypeName == typeName);

/// <summary>
/// returns the handler groups (settings, content, users, etc) that stuff can be grouped into
/// </summary>
public IEnumerable<string> GetGroups()
=> syncHandlers.ExtendedHandlers
.Select(x => x.Group)
.Distinct();

/// <summary>
/// returns the list of handler sets in the config
/// </summary>
public IEnumerable<string> GetSets()
=> config.Settings.HandlerSets.Select(x => x.Name)

#endregion

#region Default Config Loaders - for when you know exactly what you want
Expand Down

0 comments on commit a44137a

Please sign in to comment.