mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 00:46:02 +08:00
Update svn properties.
This commit is contained in:
@@ -1,39 +1,39 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using OpenSim.Region.OptionalModules.Scripting.Minimodule.Interfaces;
|
||||
|
||||
namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
||||
{
|
||||
class ExtensionHandler : IExtension
|
||||
{
|
||||
private readonly Dictionary<Type, object> m_instances;
|
||||
|
||||
public ExtensionHandler(Dictionary<Type, object> instances)
|
||||
{
|
||||
m_instances = instances;
|
||||
}
|
||||
|
||||
public T Get<T>()
|
||||
{
|
||||
return (T) m_instances[typeof (T)];
|
||||
}
|
||||
|
||||
public bool TryGet<T>(out T extension)
|
||||
{
|
||||
if (!m_instances.ContainsKey(typeof(T)))
|
||||
{
|
||||
extension = default(T);
|
||||
return false;
|
||||
}
|
||||
|
||||
extension = Get<T>();
|
||||
return true;
|
||||
}
|
||||
|
||||
public bool Has<T>()
|
||||
{
|
||||
return m_instances.ContainsKey(typeof (T));
|
||||
}
|
||||
}
|
||||
}
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using OpenSim.Region.OptionalModules.Scripting.Minimodule.Interfaces;
|
||||
|
||||
namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
||||
{
|
||||
class ExtensionHandler : IExtension
|
||||
{
|
||||
private readonly Dictionary<Type, object> m_instances;
|
||||
|
||||
public ExtensionHandler(Dictionary<Type, object> instances)
|
||||
{
|
||||
m_instances = instances;
|
||||
}
|
||||
|
||||
public T Get<T>()
|
||||
{
|
||||
return (T) m_instances[typeof (T)];
|
||||
}
|
||||
|
||||
public bool TryGet<T>(out T extension)
|
||||
{
|
||||
if (!m_instances.ContainsKey(typeof(T)))
|
||||
{
|
||||
extension = default(T);
|
||||
return false;
|
||||
}
|
||||
|
||||
extension = Get<T>();
|
||||
return true;
|
||||
}
|
||||
|
||||
public bool Has<T>()
|
||||
{
|
||||
return m_instances.ContainsKey(typeof (T));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
||||
{
|
||||
public interface IMRMModule
|
||||
{
|
||||
void RegisterExtension<T>(T instance);
|
||||
}
|
||||
namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
||||
{
|
||||
public interface IMRMModule
|
||||
{
|
||||
void RegisterExtension<T>(T instance);
|
||||
}
|
||||
}
|
||||
@@ -1,13 +1,13 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace OpenSim.Region.OptionalModules.Scripting.Minimodule.Interfaces
|
||||
{
|
||||
public interface IExtension
|
||||
{
|
||||
T Get<T>();
|
||||
bool TryGet<T>(out T extension);
|
||||
bool Has<T>();
|
||||
}
|
||||
}
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace OpenSim.Region.OptionalModules.Scripting.Minimodule.Interfaces
|
||||
{
|
||||
public interface IExtension
|
||||
{
|
||||
T Get<T>();
|
||||
bool TryGet<T>(out T extension);
|
||||
bool Has<T>();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,48 +1,48 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using OpenMetaverse;
|
||||
|
||||
namespace OpenSim.Region.OptionalModules.Scripting.Minimodule.Object
|
||||
{
|
||||
public enum SculptType
|
||||
{
|
||||
Default = 1,
|
||||
Sphere = 1,
|
||||
Torus = 2,
|
||||
Plane = 3,
|
||||
Cylinder = 4
|
||||
}
|
||||
|
||||
public enum HoleShape
|
||||
{
|
||||
Default = 0x00,
|
||||
Circle = 0x10,
|
||||
Square = 0x20,
|
||||
Triangle = 0x30
|
||||
}
|
||||
|
||||
public enum PrimType
|
||||
{
|
||||
NotPrimitive = 255,
|
||||
Box = 0,
|
||||
Cylinder = 1,
|
||||
Prism = 2,
|
||||
Sphere = 3,
|
||||
Torus = 4,
|
||||
Tube = 5,
|
||||
Ring = 6,
|
||||
Sculpt = 7
|
||||
}
|
||||
|
||||
public interface IObjectShape
|
||||
{
|
||||
UUID SculptMap { get; set; }
|
||||
SculptType SculptType { get; set; }
|
||||
|
||||
HoleShape HoleType { get; set; }
|
||||
Double HoleSize { get; set; }
|
||||
PrimType PrimType { get; set; }
|
||||
|
||||
}
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using OpenMetaverse;
|
||||
|
||||
namespace OpenSim.Region.OptionalModules.Scripting.Minimodule.Object
|
||||
{
|
||||
public enum SculptType
|
||||
{
|
||||
Default = 1,
|
||||
Sphere = 1,
|
||||
Torus = 2,
|
||||
Plane = 3,
|
||||
Cylinder = 4
|
||||
}
|
||||
|
||||
public enum HoleShape
|
||||
{
|
||||
Default = 0x00,
|
||||
Circle = 0x10,
|
||||
Square = 0x20,
|
||||
Triangle = 0x30
|
||||
}
|
||||
|
||||
public enum PrimType
|
||||
{
|
||||
NotPrimitive = 255,
|
||||
Box = 0,
|
||||
Cylinder = 1,
|
||||
Prism = 2,
|
||||
Sphere = 3,
|
||||
Torus = 4,
|
||||
Tube = 5,
|
||||
Ring = 6,
|
||||
Sculpt = 7
|
||||
}
|
||||
|
||||
public interface IObjectShape
|
||||
{
|
||||
UUID SculptMap { get; set; }
|
||||
SculptType SculptType { get; set; }
|
||||
|
||||
HoleShape HoleType { get; set; }
|
||||
Double HoleSize { get; set; }
|
||||
PrimType PrimType { get; set; }
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user