I hereby claim:
- I am athraen on github.
- I am athraen (https://keybase.io/athraen) on keybase.
- I have a public key ASASD5YWua_P7z_A2vOv5Tes43qtiJ77ruZdycI3Oa2HBgo
To claim this, I am signing this object:
| using EPiServer.Forms.Core.VisitorData; | |
| using EPiServer.ServiceLocation; | |
| using Microsoft.Extensions.Primitives; | |
| namespace FormsFun.Business.Forms; | |
| [ServiceConfiguration(ServiceType = typeof(IVisitorDataSource))] | |
| public class UTMParametersDataSource(IHttpContextAccessor httpContextAccessor, ILogger<UTMParametersDataSource> logger) : IVisitorDataSource | |
| { | |
| //Remember to add services.AddHttpContextAccessor() in your startup / DI registration. |
| using EPiServer.Cms.Shell.UI.Rest; | |
| using EPiServer.Core; | |
| using EPiServer.DataAbstraction; | |
| using EPiServer.ServiceLocation; | |
| using EPiServer; | |
| using System.Collections.Generic; | |
| using CodeArt.Web.Models.Pages; | |
| namespace CodeArt.Web.Business.SuggestedTypes | |
| { |
| public class VisitorGroupSyncService | |
| { | |
| private readonly IVisitorGroupRepository _visitorGroupRepository; | |
| private readonly IVisitorGroupCriterionRepository _visitorGroupCriterionRepository; | |
| public VisitorGroupSyncService(IVisitorGroupRepository visitorGroupRepository, IVisitorGroupCriterionRepository visitorGroupCriterionRepository) | |
| { | |
| _visitorGroupRepository = visitorGroupRepository; | |
| _visitorGroupCriterionRepository = visitorGroupCriterionRepository; | |
| } |
| public class CustomStringConversionJsonConverter<G> : JsonConverter<G> | |
| { | |
| private readonly Func<G, string> _convertToString; | |
| private readonly Func<string, G> _convertFromString; | |
| public CustomStringConversionJsonConverter(Func<G,string> ConvertToString, Func<string,G> ConvertFromString) | |
| { | |
| _convertFromString = ConvertFromString; | |
| _convertToString = ConvertToString; | |
| } | |
| //Register the PDF's as a specific content type in Optimizely. Ensure Guid is unique. | |
| //Connect to Digizuite asset-types using the DigizuiteType attribute. | |
| [ContentType(DisplayName = "Downloadable Digizuite File", GUID = "a4ca5288-35ce-4ee5-b094-72f76ca8e07b", Description = "", AvailableInEditMode = false)] | |
| [DigizuiteType(AssetTypeIds = new[] { Digizuite.Optimizely.Constants.GlobalConstants.AssetTypes.PDF })] | |
| public class DownloadableDocument : DigizuiteFile | |
| { | |
| } |
I hereby claim:
To claim this, I am signing this object:
| using EPiServer.PlugIn; | |
| using EPiServer.Shell.ObjectEditing; | |
| using System.ComponentModel.DataAnnotations; | |
| /// <summary> | |
| /// Rule that specifies where a certain type of content should be put on creation | |
| /// </summary> | |
| public class ContentCreationRule | |
| { | |
| [Display(Name = "Content Type", Order = 10)] |
| public class GenericEnumSelectionFactory<TEnum> : EnumSelectionFactory where TEnum : Enum | |
| { | |
| protected override Type EnumType => typeof(TEnum); | |
| public GenericEnumSelectionFactory() : this(LocalizationService.Current) | |
| { | |
| } | |
| public GenericEnumSelectionFactory(LocalizationService localization) : base(localization) | |
| { |
| public class DependentPropertyAttribute : Attribute | |
| { | |
| public string DependentProperty { get; set; } | |
| public object Value { get; set; } | |
| public bool Compare(object value) | |
| { | |
| if (value == null) | |
| { | |
| return Value == null; |
| protected IEnumerable<List<G>> Chunkify<G>(IEnumerable<G> Source,int ChunkSize) | |
| { | |
| List<G> chunk=new List<G>(ChunkSize); | |
| foreach(var e in Source) | |
| { | |
| chunk.Add(e); | |
| if(chunk.Count > ChunkSize) | |
| { | |
| yield return chunk; | |
| chunk.Clear(); |