///// <summary> ///// Gets a list of implemented extensions. ///// </summary> //public override string[] ImplementedExtensions //{ // get { return new string[] { ExtStandard, ExtCore,/* ExtCalendar,*/ ExtCType, ExtSession, ExtTokenizer, ExtDate, ExtPcre, ExtEreg, ExtJson, ExtHash, ExtSpl }; } //} /// <summary> /// Called by the Core after the library is loaded. /// </summary> protected override void Loaded(PhpLibraryAttribute assemblyAttribute, LibraryConfigStore config) { base.Loaded(assemblyAttribute, config); singleton = this; #if !SILVERLIGHT LibraryConfiguration.RegisterLegacyOptions(); // registers session handlers: SessionHandlers.RegisterHandler(PhpSessionHandler.Default); SessionHandlers.RegisterHandler(PhpUserSessionHandler.Default); // registers serializers: Serializers.RegisterSerializer(PhpSerializer.Default); //Serializers.RegisterSerializer(PhalangerSerializer.Default); Serializers.RegisterSerializer(new ContextualSerializer("dotnet", delegate(PHP.Core.Reflection.DTypeDesc caller/*ignored*/) { return new BinaryFormatter( null, new StreamingContext(StreamingContextStates.Persistence, new SerializationContext())); })); #endif }
///// <summary> ///// Gets a list of implemented extensions. ///// </summary> //public override string[] ImplementedExtensions //{ // get { return new string[] { ExtStandard, ExtCore,/* ExtCalendar,*/ ExtCType, ExtSession, ExtTokenizer, ExtDate, ExtPcre, ExtEreg, ExtJson, ExtHash, ExtSpl }; } //} /// <summary> /// Called by the Core after the library is loaded. /// </summary> protected override void Loaded(PhpLibraryAttribute assemblyAttribute, LibraryConfigStore config) { base.Loaded(assemblyAttribute, config); singleton = this; #if !SILVERLIGHT LibraryConfiguration.RegisterLegacyOptions(); // registers session handlers: SessionHandlers.RegisterHandler(PhpSessionHandler.Default); SessionHandlers.RegisterHandler(PhpUserSessionHandler.Default); SessionHandlers.RegisterHandler(AspNetThruSessionHandler.Default); // registers serializers: Serializers.RegisterSerializer(PhpSerializer.Default); //Serializers.RegisterSerializer(PhalangerSerializer.Default); Serializers.RegisterSerializer(new ContextualSerializer("dotnet", delegate(PHP.Core.Reflection.DTypeDesc caller /*ignored*/) { return(new BinaryFormatter( null, new StreamingContext(StreamingContextStates.Persistence, new SerializationContext()))); })); #endif }