├── pjsip4net
├── Media
│ └── IIdenitfiable.cs
├── Sounds
│ ├── busy.wav
│ ├── ring.wav
│ ├── dial_tone.wav
│ └── old-phone-ring6.wav
├── Interfaces
│ ├── IObjectFactory.cs
│ ├── IWavRecorder.cs
│ ├── IFileSourceMedia.cs
│ ├── IMediaSource.cs
│ ├── IVoIPTransportFactory.cs
│ ├── IWavPlayer.cs
│ ├── ICallBuilder.cs
│ ├── IBuddyBuilder.cs
│ ├── ITlsTransport.cs
│ ├── IMessageBuilder.cs
│ ├── IBuddy.cs
│ ├── IConferenceBridge.cs
│ ├── IRegistry.cs
│ ├── IVoIPTransport.cs
│ ├── ISipUserAgent.cs
│ ├── IMediaManager.cs
│ ├── IAccountManager.cs
│ ├── IImManager.cs
│ └── IAccount.cs
├── packages.config
├── Calls
│ ├── CallRedirectedEventArgs.cs
│ ├── IncomingCallEventArgs.cs
│ ├── CallTransferEventArgs.cs
│ ├── CallStateChangedEventArgs.cs
│ ├── DtmfEventArgs.cs
│ ├── RingEventArgs.cs
│ ├── DisconnectedMediaState.cs
│ ├── ErrorMediaState.cs
│ ├── NullInviteState.cs
│ ├── ConnectingInviteState.cs
│ ├── ConferenceMediaStateDecorator.cs
│ ├── EarlyInviteState.cs
│ ├── NoneMediaState.cs
│ ├── SignallingSession.cs
│ ├── CallingInviteState.cs
│ ├── DisconnectedInviteState.cs
│ ├── IncomingInviteState.cs
│ └── ConfirmedInviteState.cs
├── Configuration
│ ├── ConfigureFromConfig.cs
│ ├── DefaultTransportComponentConfigurator.cs
│ ├── DefaultCallComponentConfigurator.cs
│ ├── DefaultAccountComponentConfigurator.cs
│ ├── DefaultMediaComponentConfigurator.cs
│ ├── DefaultAgentConfigurator.cs
│ ├── DefaultComponentConfigurator.cs
│ ├── SipUriValidator.cs
│ ├── ProxyElement.cs
│ ├── DnsServerElement.cs
│ └── StunElement.cs
├── Transport
│ ├── TcpTransport.cs
│ ├── UdpTransport.cs
│ └── DefaultVoIPTransportFactory.cs
├── TypingEventArgs.cs
├── Accounts
│ ├── AccountStateChangedEventArgs.cs
│ ├── RegistrationSession.cs
│ ├── InitializingAccountState.cs
│ ├── RegisteringAccountState.cs
│ ├── TimedOutAccountRegistrationState.cs
│ └── UnknownStatusState.cs
├── IM
│ └── BuddyStateChangedEventArgs.cs
├── LogEventArgs.cs
├── Properties
│ └── AssemblyInfo.cs
├── NatEventArgs.cs
├── DefaultObjectFactory.cs
├── PagerEventArgs.cs
├── Logging.cs
└── DefaultRegistry.cs
├── lib
├── NUnit
│ ├── runpnunit.bat
│ ├── nunit.exe
│ ├── lib
│ │ ├── fit.dll
│ │ ├── Failure.png
│ │ ├── Ignored.png
│ │ ├── Skipped.png
│ │ ├── Success.png
│ │ ├── log4net.dll
│ │ ├── nunit.core.dll
│ │ ├── nunit.util.dll
│ │ ├── Inconclusive.png
│ │ ├── nunit.uikit.dll
│ │ ├── nunit.fixtures.dll
│ │ ├── nunit-gui-runner.dll
│ │ ├── nunit.uiexception.dll
│ │ ├── nunit-console-runner.dll
│ │ └── nunit.core.interfaces.dll
│ ├── nunit-x86.exe
│ ├── runFile.exe
│ ├── nunit-agent.exe
│ ├── nunit-console.exe
│ ├── pnunit-agent.exe
│ ├── pnunit.tests.dll
│ ├── nunit-agent-x86.exe
│ ├── nunit.framework.dll
│ ├── pnunit-launcher.exe
│ ├── pnunit.framework.dll
│ ├── nunit-console-x86.exe
│ ├── tests
│ │ ├── mock-assembly.dll
│ │ ├── test-assembly.dll
│ │ ├── timing-tests.dll
│ │ ├── nunit-gui.tests.dll
│ │ ├── nunit.framework.dll
│ │ ├── test-utilities.dll
│ │ ├── loadtest-assembly.dll
│ │ ├── nunit.core.tests.dll
│ │ ├── nunit.mocks.tests.dll
│ │ ├── nunit.uikit.tests.dll
│ │ ├── nunit.util.tests.dll
│ │ ├── nonamespace-assembly.dll
│ │ ├── nunit-console.tests.dll
│ │ ├── nunit.fixtures.tests.dll
│ │ ├── nunit.framework.tests.dll
│ │ └── nunit.uiexception.tests.dll
│ ├── agent.conf
│ ├── framework
│ │ ├── nunit.mocks.dll
│ │ ├── nunit.framework.dll
│ │ └── pnunit.framework.dll
│ ├── agent.log.conf
│ ├── launcher.log.conf
│ ├── NUnitTests.nunit
│ └── test.conf
├── Moq
│ └── Moq.dll
├── MoMA
│ ├── MoMA.exe
│ ├── Mono.Cecil.dll
│ ├── MoMA.Analyzer.dll
│ ├── Resources
│ │ ├── spinner.gif
│ │ ├── button_ok.png
│ │ ├── dialogback.png
│ │ ├── list-add.png
│ │ ├── monoback.png
│ │ ├── list-remove.png
│ │ ├── dialog-warning.png
│ │ └── list-directory.png
│ ├── Definitions
│ │ ├── 2.6-defs.zip
│ │ └── 2.4.0.1-defs.zip
│ ├── Reports
│ │ └── Media
│ │ │ ├── fail.png
│ │ │ ├── minus.png
│ │ │ ├── pass.png
│ │ │ ├── plus.png
│ │ │ └── moma.js
│ └── ICSharpCode.SharpZipLib.dll
├── NAnt
│ ├── NAnt.exe
│ ├── scvs.exe
│ ├── log4net.dll
│ ├── NAnt.Core.dll
│ ├── NAnt.NUnit.dll
│ ├── QuickGraph.dll
│ ├── SLiNgshoT.exe
│ ├── MbUnit.Tasks.dll
│ ├── CollectionGen.dll
│ ├── MSITaskErrors.mst
│ ├── MSITaskTemplate.msi
│ ├── MSMTaskErrors.mst
│ ├── MSMTaskTemplate.msm
│ ├── NAnt.MSNetTasks.dll
│ ├── NAnt.VSNetTasks.dll
│ ├── NAnt.Win32Tasks.dll
│ ├── SLiNgshoT.Core.dll
│ ├── Interop.StarTeam.dll
│ ├── MbUnit.Framework.dll
│ ├── NAnt.DotNetTasks.dll
│ ├── NAnt.NUnit1Tasks.dll
│ ├── NAnt.NUnit2Tasks.dll
│ ├── NAnt.Contrib.Tasks.dll
│ ├── NAnt.VisualCppTasks.dll
│ ├── NDoc.Documenter.NAnt.dll
│ ├── SourceSafe.Interop.dll
│ ├── NAnt.CompressionTasks.dll
│ ├── QuickGraph.Algorithms.dll
│ ├── lib
│ │ ├── mono
│ │ │ └── 2.0
│ │ │ │ ├── NDoc.Core.dll
│ │ │ │ ├── nunit.core.dll
│ │ │ │ ├── nunit.util.dll
│ │ │ │ ├── NDoc.ExtendedUI.dll
│ │ │ │ ├── nunit.framework.dll
│ │ │ │ └── NDoc.Documenter.Msdn.dll
│ │ ├── net
│ │ │ ├── 1.0
│ │ │ │ ├── NDoc.Core.dll
│ │ │ │ ├── nunit.core.dll
│ │ │ │ ├── nunit.util.dll
│ │ │ │ ├── nunit-console.exe
│ │ │ │ ├── NDoc.ExtendedUI.dll
│ │ │ │ ├── nunit.framework.dll
│ │ │ │ ├── NDoc.Documenter.Msdn.dll
│ │ │ │ └── nunit-console-runner.dll
│ │ │ └── 2.0
│ │ │ │ ├── NDoc.Core.dll
│ │ │ │ ├── nunit.core.dll
│ │ │ │ ├── nunit.util.dll
│ │ │ │ ├── NDoc.ExtendedUI.dll
│ │ │ │ ├── nunit.framework.dll
│ │ │ │ └── NDoc.Documenter.Msdn.dll
│ │ └── common
│ │ │ ├── 1.1
│ │ │ ├── nunit.core.dll
│ │ │ ├── nunit.util.dll
│ │ │ ├── nunit-console.exe
│ │ │ ├── nunit.framework.dll
│ │ │ └── nunit-console-runner.dll
│ │ │ ├── 2.0
│ │ │ ├── nunit.core.dll
│ │ │ ├── nunit.util.dll
│ │ │ ├── nunit-console.exe
│ │ │ ├── nunit.framework.dll
│ │ │ └── nunit-console-runner.dll
│ │ │ └── neutral
│ │ │ ├── NDoc.Core.dll
│ │ │ ├── NUnitCore.dll
│ │ │ ├── NDoc.ExtendedUI.dll
│ │ │ ├── NDoc.Documenter.Msdn.dll
│ │ │ ├── ICSharpCode.SharpCvsLib.dll
│ │ │ ├── ICSharpCode.SharpZipLib.dll
│ │ │ └── ICSharpCode.SharpCvsLib.Console.dll
│ ├── Interop.MsmMergeTypeLib.dll
│ ├── Interop.WindowsInstaller.dll
│ ├── NAnt.SourceControlTasks.dll
│ ├── NCoverExplorer.NAntTasks.dll
│ ├── NDepend.Build.NAntTasks.dll
│ ├── ThoughtWorks.CruiseControl.MSBuild.dll
│ └── extensions
│ │ └── common
│ │ └── 2.0
│ │ ├── NAnt.MSBuild.dll
│ │ └── NAnt.MSBuild.xml
├── NuGet
│ └── NuGet.exe
├── pjsip
│ ├── pjsua.dll
│ ├── libeay32.dll
│ ├── ssleay32.dll
│ └── pjsua-i386-Win32-vc8-Debug.exe
├── NCover
│ ├── CoverLib.dll
│ ├── MSVCP80.dll
│ ├── MSVCR80.dll
│ ├── ActiproEULA.html
│ ├── CommandBars.dll
│ ├── NCover.Console.exe
│ ├── NCoverExplorer.exe
│ ├── NCover.Framework.dll
│ ├── NCoverExplorerFAQ.html
│ ├── NCoverExplorer.Core.dll
│ ├── ICSharpCode.TextEditor.dll
│ ├── NCoverExplorer.Console.exe
│ ├── NCoverExplorer.WinForms.dll
│ ├── ActiproSoftware.Shared.Net11.dll
│ ├── NCoverExplorer.NCoverRunner.dll
│ ├── ActiproSoftware.WinUICore.Net11.dll
│ ├── ActiproSoftware.SyntaxEditor.Net11.dll
│ ├── NCover.Console.exe.config
│ ├── NCoverExplorer.exe.config
│ └── VC80CRT.MAN
├── NuGet.Core
│ ├── NuGet.Core.nupkg
│ └── lib
│ │ └── net40
│ │ └── NuGet.Core.dll
├── ReportGenerator
│ ├── log4net.dll
│ ├── ReportGenerator.exe
│ └── ICSharpCode.NRefactory.dll
└── AutoFixture
│ ├── Ploeh.AutoFixture.dll
│ ├── Ploeh.AutoFixture.AutoMoq.dll
│ └── Ploeh.SemanticComparison.dll
├── nuget
├── build
│ ├── x86
│ │ ├── pjsua.dl_
│ │ ├── libeay32.dl_
│ │ └── ssleay32.dl_
│ └── pjsip4net.targets
└── pjsip4net.nuspec
├── settings
├── SettingsFileReadMe.txt
└── LOCAL.settings
├── pjsip4net.Core
├── Data
│ ├── Events
│ │ ├── CallStateChanged.cs
│ │ ├── PlayerCompleted.cs
│ │ ├── StreamDestroyed.cs
│ │ ├── BuddyStateChanged.cs
│ │ ├── CallMediaStateChanged.cs
│ │ ├── RegistrationStateChanged.cs
│ │ ├── StateChanged.cs
│ │ ├── DtmfRecieved.cs
│ │ ├── LogRequested.cs
│ │ ├── IncomingCallRecieved.cs
│ │ ├── CallRedirected.cs
│ │ ├── CallTransferRequested.cs
│ │ ├── NatDetected.cs
│ │ ├── ImStatusChanged.cs
│ │ ├── CallTransferStatusChanged.cs
│ │ ├── IncomingTypingRecieved.cs
│ │ ├── IncomingSubscribeRecieved.cs
│ │ └── IncomingImRecieved.cs
│ ├── BuddyActivity.cs
│ ├── BuddyStatus.cs
│ ├── SrtpRequirement.cs
│ ├── BuddyConfig.cs
│ ├── RedirectOption.cs
│ ├── SipRole.cs
│ ├── MediaDirection.cs
│ ├── TransportFlags.cs
│ ├── CallMediaState.cs
│ ├── LoggingConfig.cs
│ ├── InviteState.cs
│ ├── SubscriptionState.cs
│ ├── NatType.cs
│ ├── RpidElement.cs
│ ├── TransportConfig.cs
│ ├── SignalLevel.cs
│ ├── TransportInfo.cs
│ ├── AccountInfo.cs
│ ├── TlsConfig.cs
│ ├── BuddyInfo.cs
│ ├── CallInfo.cs
│ ├── MediaConfig.cs
│ └── AccountConfig.cs
├── Interfaces
│ ├── IConfigureApi.cs
│ ├── IResource.cs
│ ├── IConfigureComponents.cs
│ ├── IConfigurationProvider.cs
│ ├── IEventsProvider.cs
│ ├── IIdentifiable.cs
│ ├── IConfigurationContext.cs
│ ├── IInitializable.cs
│ └── ApiProviders
│ │ ├── IBasicApiProvider.cs
│ │ ├── ITransportApiProvider.cs
│ │ ├── IIMApiProvider.cs
│ │ └── IAccountApiProvider.cs
├── TransportType.cs
├── Utils
│ ├── ValidFileNameTemplate.cs
│ ├── EventArgs.cs
│ ├── Tuple.cs
│ ├── AbstractState.cs
│ ├── StringBuilderExtension.cs
│ ├── ValueWrapper.cs
│ ├── TransitionFunction.cs
│ ├── EqualsTemplate.cs
│ ├── StateMachine.cs
│ ├── NfaState.cs
│ └── SingletonHolder.cs
├── packages.config
├── Configuration
│ ├── CoreComponentConfigurator.cs
│ └── ConfigureContainer.cs
├── Properties
│ └── AssemblyInfo.cs
├── PjsipErrorException.cs
├── Container
│ └── ContainerException.cs
├── DelegatingConsumer.cs
├── EventsProvider.cs
└── Resource.cs
├── uppercutbuild.rb
├── pjsip.Interop
├── packages.config
├── Services
│ ├── SoundDeviceInfoConverter.cs
│ ├── Pjsip4net2PjsuaProfile.cs
│ ├── Pjsua2Pjsip4netProfile.cs
│ ├── TransportInfoConverter.cs
│ ├── ConferencePortInfoConverter.cs
│ ├── AccountInfoConverter.cs
│ └── CallInfoConverter.cs
├── ConfigureVersion_1_4.cs
├── Interfaces
│ └── IMapper.cs
├── TransportTypeExtensions.cs
├── Properties
│ └── AssemblyInfo.cs
└── Version_1_4_ComponentConfigurator.cs
├── Tests
├── Integration
│ └── pjsip4net.Console
│ │ ├── ICommand.cs
│ │ ├── ICommandFactory.cs
│ │ ├── NeroSoundTrax_test8_PCM_Mono_VBR_16SS_48000Hz.wav
│ │ └── packages.config
├── Unit
│ └── pjsip4net.Tests
│ │ ├── Properties
│ │ └── AssemblyInfo.cs
│ │ ├── packages.config
│ │ ├── App.config
│ │ ├── _base.cs
│ │ ├── pjsip4net.Tests.csproj.user
│ │ ├── Calls
│ │ └── CallCustomization.cs
│ │ ├── given_a_valueWrapper.cs
│ │ ├── given_a_default_transport_configurator.cs
│ │ ├── Accounts
│ │ └── AccountCustomization.cs
│ │ ├── given_a_default_call_configurator.cs
│ │ ├── given_a_default_account_component_configurator.cs
│ │ ├── given_a_component_configurator.cs
│ │ ├── given_bcl_extensions.cs
│ │ └── given_a_default_media_configurator.cs
└── pjsip4net.Testing
│ ├── Properties
│ └── AssemblyInfo.cs
│ ├── ConfigureForTest.cs
│ ├── TestConfigurator.cs
│ ├── TransportApiTestProvider.cs
│ ├── BasicApiTestProvider.cs
│ └── ImApiTestProvider.cs
├── deployment
└── templates
│ ├── AppDeployment.bat
│ ├── DBDeployment.bat
│ └── DBDeployment.RESTORE.bat
├── pjsip4net.Container.Castle
├── packages.config
├── Properties
│ └── AssemblyInfo.cs
└── ConfigureCastleContainer.cs
├── open.sh
├── zip.sh
├── open.bat
├── license.txt
├── zip.bat
├── uppercut
├── project.rb
├── config.rb
└── cli.rb
├── gems
└── __RENAME__.gemspec.rename
├── .github
└── ISSUE_TEMPLATE
│ └── bug_report.md
└── test.bat
/pjsip4net/Media/IIdenitfiable.cs:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/lib/NUnit/runpnunit.bat:
--------------------------------------------------------------------------------
1 | start pnunit-agent agent.conf
2 | pnunit-launcher test.conf
--------------------------------------------------------------------------------
/lib/Moq/Moq.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/Moq/Moq.dll
--------------------------------------------------------------------------------
/lib/MoMA/MoMA.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/MoMA.exe
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.exe
--------------------------------------------------------------------------------
/lib/NAnt/scvs.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/scvs.exe
--------------------------------------------------------------------------------
/lib/NAnt/log4net.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/log4net.dll
--------------------------------------------------------------------------------
/lib/NUnit/nunit.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/nunit.exe
--------------------------------------------------------------------------------
/lib/NuGet/NuGet.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NuGet/NuGet.exe
--------------------------------------------------------------------------------
/lib/pjsip/pjsua.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/pjsip/pjsua.dll
--------------------------------------------------------------------------------
/lib/MoMA/Mono.Cecil.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Mono.Cecil.dll
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.Core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.Core.dll
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.NUnit.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.NUnit.dll
--------------------------------------------------------------------------------
/lib/NAnt/QuickGraph.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/QuickGraph.dll
--------------------------------------------------------------------------------
/lib/NAnt/SLiNgshoT.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/SLiNgshoT.exe
--------------------------------------------------------------------------------
/lib/NCover/CoverLib.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/CoverLib.dll
--------------------------------------------------------------------------------
/lib/NCover/MSVCP80.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/MSVCP80.dll
--------------------------------------------------------------------------------
/lib/NCover/MSVCR80.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/MSVCR80.dll
--------------------------------------------------------------------------------
/lib/NUnit/lib/fit.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/fit.dll
--------------------------------------------------------------------------------
/lib/NUnit/nunit-x86.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/nunit-x86.exe
--------------------------------------------------------------------------------
/lib/NUnit/runFile.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/runFile.exe
--------------------------------------------------------------------------------
/lib/pjsip/libeay32.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/pjsip/libeay32.dll
--------------------------------------------------------------------------------
/lib/pjsip/ssleay32.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/pjsip/ssleay32.dll
--------------------------------------------------------------------------------
/lib/NAnt/MbUnit.Tasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/MbUnit.Tasks.dll
--------------------------------------------------------------------------------
/lib/NUnit/lib/Failure.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/Failure.png
--------------------------------------------------------------------------------
/lib/NUnit/lib/Ignored.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/Ignored.png
--------------------------------------------------------------------------------
/lib/NUnit/lib/Skipped.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/Skipped.png
--------------------------------------------------------------------------------
/lib/NUnit/lib/Success.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/Success.png
--------------------------------------------------------------------------------
/lib/NUnit/lib/log4net.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/log4net.dll
--------------------------------------------------------------------------------
/lib/NUnit/nunit-agent.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/nunit-agent.exe
--------------------------------------------------------------------------------
/nuget/build/x86/pjsua.dl_:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/nuget/build/x86/pjsua.dl_
--------------------------------------------------------------------------------
/pjsip4net/Sounds/busy.wav:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/pjsip4net/Sounds/busy.wav
--------------------------------------------------------------------------------
/pjsip4net/Sounds/ring.wav:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/pjsip4net/Sounds/ring.wav
--------------------------------------------------------------------------------
/lib/MoMA/MoMA.Analyzer.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/MoMA.Analyzer.dll
--------------------------------------------------------------------------------
/lib/NAnt/CollectionGen.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/CollectionGen.dll
--------------------------------------------------------------------------------
/lib/NAnt/MSITaskErrors.mst:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/MSITaskErrors.mst
--------------------------------------------------------------------------------
/lib/NAnt/MSITaskTemplate.msi:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/MSITaskTemplate.msi
--------------------------------------------------------------------------------
/lib/NAnt/MSMTaskErrors.mst:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/MSMTaskErrors.mst
--------------------------------------------------------------------------------
/lib/NAnt/MSMTaskTemplate.msm:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/MSMTaskTemplate.msm
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.MSNetTasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.MSNetTasks.dll
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.VSNetTasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.VSNetTasks.dll
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.Win32Tasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.Win32Tasks.dll
--------------------------------------------------------------------------------
/lib/NAnt/SLiNgshoT.Core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/SLiNgshoT.Core.dll
--------------------------------------------------------------------------------
/lib/NCover/ActiproEULA.html:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/ActiproEULA.html
--------------------------------------------------------------------------------
/lib/NCover/CommandBars.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/CommandBars.dll
--------------------------------------------------------------------------------
/lib/NUnit/lib/nunit.core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/nunit.core.dll
--------------------------------------------------------------------------------
/lib/NUnit/lib/nunit.util.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/nunit.util.dll
--------------------------------------------------------------------------------
/lib/NUnit/nunit-console.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/nunit-console.exe
--------------------------------------------------------------------------------
/lib/NUnit/pnunit-agent.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/pnunit-agent.exe
--------------------------------------------------------------------------------
/lib/NUnit/pnunit.tests.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/pnunit.tests.dll
--------------------------------------------------------------------------------
/nuget/build/x86/libeay32.dl_:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/nuget/build/x86/libeay32.dl_
--------------------------------------------------------------------------------
/nuget/build/x86/ssleay32.dl_:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/nuget/build/x86/ssleay32.dl_
--------------------------------------------------------------------------------
/lib/MoMA/Resources/spinner.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Resources/spinner.gif
--------------------------------------------------------------------------------
/lib/NAnt/Interop.StarTeam.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/Interop.StarTeam.dll
--------------------------------------------------------------------------------
/lib/NAnt/MbUnit.Framework.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/MbUnit.Framework.dll
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.DotNetTasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.DotNetTasks.dll
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.NUnit1Tasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.NUnit1Tasks.dll
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.NUnit2Tasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.NUnit2Tasks.dll
--------------------------------------------------------------------------------
/lib/NCover/NCover.Console.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/NCover.Console.exe
--------------------------------------------------------------------------------
/lib/NCover/NCoverExplorer.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/NCoverExplorer.exe
--------------------------------------------------------------------------------
/lib/NUnit/lib/Inconclusive.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/Inconclusive.png
--------------------------------------------------------------------------------
/lib/NUnit/lib/nunit.uikit.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/nunit.uikit.dll
--------------------------------------------------------------------------------
/lib/NUnit/nunit-agent-x86.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/nunit-agent-x86.exe
--------------------------------------------------------------------------------
/lib/NUnit/nunit.framework.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/nunit.framework.dll
--------------------------------------------------------------------------------
/lib/NUnit/pnunit-launcher.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/pnunit-launcher.exe
--------------------------------------------------------------------------------
/lib/NUnit/pnunit.framework.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/pnunit.framework.dll
--------------------------------------------------------------------------------
/pjsip4net/Sounds/dial_tone.wav:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/pjsip4net/Sounds/dial_tone.wav
--------------------------------------------------------------------------------
/lib/MoMA/Definitions/2.6-defs.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Definitions/2.6-defs.zip
--------------------------------------------------------------------------------
/lib/MoMA/Reports/Media/fail.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Reports/Media/fail.png
--------------------------------------------------------------------------------
/lib/MoMA/Reports/Media/minus.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Reports/Media/minus.png
--------------------------------------------------------------------------------
/lib/MoMA/Reports/Media/pass.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Reports/Media/pass.png
--------------------------------------------------------------------------------
/lib/MoMA/Reports/Media/plus.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Reports/Media/plus.png
--------------------------------------------------------------------------------
/lib/MoMA/Resources/button_ok.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Resources/button_ok.png
--------------------------------------------------------------------------------
/lib/MoMA/Resources/dialogback.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Resources/dialogback.png
--------------------------------------------------------------------------------
/lib/MoMA/Resources/list-add.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Resources/list-add.png
--------------------------------------------------------------------------------
/lib/MoMA/Resources/monoback.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Resources/monoback.png
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.Contrib.Tasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.Contrib.Tasks.dll
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.VisualCppTasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.VisualCppTasks.dll
--------------------------------------------------------------------------------
/lib/NAnt/NDoc.Documenter.NAnt.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NDoc.Documenter.NAnt.dll
--------------------------------------------------------------------------------
/lib/NAnt/SourceSafe.Interop.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/SourceSafe.Interop.dll
--------------------------------------------------------------------------------
/lib/NCover/NCover.Framework.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/NCover.Framework.dll
--------------------------------------------------------------------------------
/lib/NCover/NCoverExplorerFAQ.html:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/NCoverExplorerFAQ.html
--------------------------------------------------------------------------------
/lib/NUnit/lib/nunit.fixtures.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/nunit.fixtures.dll
--------------------------------------------------------------------------------
/lib/NUnit/nunit-console-x86.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/nunit-console-x86.exe
--------------------------------------------------------------------------------
/lib/NUnit/tests/mock-assembly.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/mock-assembly.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/test-assembly.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/test-assembly.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/timing-tests.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/timing-tests.dll
--------------------------------------------------------------------------------
/lib/NuGet.Core/NuGet.Core.nupkg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NuGet.Core/NuGet.Core.nupkg
--------------------------------------------------------------------------------
/lib/ReportGenerator/log4net.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/ReportGenerator/log4net.dll
--------------------------------------------------------------------------------
/lib/MoMA/Resources/list-remove.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Resources/list-remove.png
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.CompressionTasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.CompressionTasks.dll
--------------------------------------------------------------------------------
/lib/NAnt/QuickGraph.Algorithms.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/QuickGraph.Algorithms.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/mono/2.0/NDoc.Core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/mono/2.0/NDoc.Core.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/1.0/NDoc.Core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/1.0/NDoc.Core.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/1.0/nunit.core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/1.0/nunit.core.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/1.0/nunit.util.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/1.0/nunit.util.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/2.0/NDoc.Core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/2.0/NDoc.Core.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/2.0/nunit.core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/2.0/nunit.core.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/2.0/nunit.util.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/2.0/nunit.util.dll
--------------------------------------------------------------------------------
/lib/NCover/NCoverExplorer.Core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/NCoverExplorer.Core.dll
--------------------------------------------------------------------------------
/lib/NUnit/agent.conf:
--------------------------------------------------------------------------------
1 |
2 | 8080
3 | .
4 |
--------------------------------------------------------------------------------
/lib/NUnit/framework/nunit.mocks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/framework/nunit.mocks.dll
--------------------------------------------------------------------------------
/lib/NUnit/lib/nunit-gui-runner.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/nunit-gui-runner.dll
--------------------------------------------------------------------------------
/lib/NUnit/lib/nunit.uiexception.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/nunit.uiexception.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/nunit-gui.tests.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/nunit-gui.tests.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/nunit.framework.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/nunit.framework.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/test-utilities.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/test-utilities.dll
--------------------------------------------------------------------------------
/lib/AutoFixture/Ploeh.AutoFixture.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/AutoFixture/Ploeh.AutoFixture.dll
--------------------------------------------------------------------------------
/lib/MoMA/Definitions/2.4.0.1-defs.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Definitions/2.4.0.1-defs.zip
--------------------------------------------------------------------------------
/lib/MoMA/ICSharpCode.SharpZipLib.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/ICSharpCode.SharpZipLib.dll
--------------------------------------------------------------------------------
/lib/MoMA/Resources/dialog-warning.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Resources/dialog-warning.png
--------------------------------------------------------------------------------
/lib/MoMA/Resources/list-directory.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/MoMA/Resources/list-directory.png
--------------------------------------------------------------------------------
/lib/NAnt/Interop.MsmMergeTypeLib.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/Interop.MsmMergeTypeLib.dll
--------------------------------------------------------------------------------
/lib/NAnt/Interop.WindowsInstaller.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/Interop.WindowsInstaller.dll
--------------------------------------------------------------------------------
/lib/NAnt/NAnt.SourceControlTasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NAnt.SourceControlTasks.dll
--------------------------------------------------------------------------------
/lib/NAnt/NCoverExplorer.NAntTasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NCoverExplorer.NAntTasks.dll
--------------------------------------------------------------------------------
/lib/NAnt/NDepend.Build.NAntTasks.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/NDepend.Build.NAntTasks.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/1.1/nunit.core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/1.1/nunit.core.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/1.1/nunit.util.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/1.1/nunit.util.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/2.0/nunit.core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/2.0/nunit.core.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/2.0/nunit.util.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/2.0/nunit.util.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/mono/2.0/nunit.core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/mono/2.0/nunit.core.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/mono/2.0/nunit.util.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/mono/2.0/nunit.util.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/1.0/nunit-console.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/1.0/nunit-console.exe
--------------------------------------------------------------------------------
/lib/NCover/ICSharpCode.TextEditor.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/ICSharpCode.TextEditor.dll
--------------------------------------------------------------------------------
/lib/NCover/NCoverExplorer.Console.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/NCoverExplorer.Console.exe
--------------------------------------------------------------------------------
/lib/NCover/NCoverExplorer.WinForms.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/NCoverExplorer.WinForms.dll
--------------------------------------------------------------------------------
/lib/NUnit/lib/nunit-console-runner.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/nunit-console-runner.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/loadtest-assembly.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/loadtest-assembly.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/nunit.core.tests.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/nunit.core.tests.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/nunit.mocks.tests.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/nunit.mocks.tests.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/nunit.uikit.tests.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/nunit.uikit.tests.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/nunit.util.tests.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/nunit.util.tests.dll
--------------------------------------------------------------------------------
/pjsip4net/Sounds/old-phone-ring6.wav:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/pjsip4net/Sounds/old-phone-ring6.wav
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/1.0/NDoc.ExtendedUI.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/1.0/NDoc.ExtendedUI.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/1.0/nunit.framework.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/1.0/nunit.framework.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/2.0/NDoc.ExtendedUI.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/2.0/NDoc.ExtendedUI.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/2.0/nunit.framework.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/2.0/nunit.framework.dll
--------------------------------------------------------------------------------
/lib/NUnit/framework/nunit.framework.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/framework/nunit.framework.dll
--------------------------------------------------------------------------------
/lib/NUnit/framework/pnunit.framework.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/framework/pnunit.framework.dll
--------------------------------------------------------------------------------
/lib/NUnit/lib/nunit.core.interfaces.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/lib/nunit.core.interfaces.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/nonamespace-assembly.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/nonamespace-assembly.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/nunit-console.tests.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/nunit-console.tests.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/nunit.fixtures.tests.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/nunit.fixtures.tests.dll
--------------------------------------------------------------------------------
/lib/NuGet.Core/lib/net40/NuGet.Core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NuGet.Core/lib/net40/NuGet.Core.dll
--------------------------------------------------------------------------------
/lib/ReportGenerator/ReportGenerator.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/ReportGenerator/ReportGenerator.exe
--------------------------------------------------------------------------------
/lib/pjsip/pjsua-i386-Win32-vc8-Debug.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/pjsip/pjsua-i386-Win32-vc8-Debug.exe
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/1.1/nunit-console.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/1.1/nunit-console.exe
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/1.1/nunit.framework.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/1.1/nunit.framework.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/2.0/nunit-console.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/2.0/nunit-console.exe
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/2.0/nunit.framework.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/2.0/nunit.framework.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/neutral/NDoc.Core.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/neutral/NDoc.Core.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/neutral/NUnitCore.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/neutral/NUnitCore.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/mono/2.0/NDoc.ExtendedUI.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/mono/2.0/NDoc.ExtendedUI.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/mono/2.0/nunit.framework.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/mono/2.0/nunit.framework.dll
--------------------------------------------------------------------------------
/lib/NCover/ActiproSoftware.Shared.Net11.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/ActiproSoftware.Shared.Net11.dll
--------------------------------------------------------------------------------
/lib/NCover/NCoverExplorer.NCoverRunner.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/NCoverExplorer.NCoverRunner.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/nunit.framework.tests.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/nunit.framework.tests.dll
--------------------------------------------------------------------------------
/lib/NUnit/tests/nunit.uiexception.tests.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NUnit/tests/nunit.uiexception.tests.dll
--------------------------------------------------------------------------------
/lib/AutoFixture/Ploeh.AutoFixture.AutoMoq.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/AutoFixture/Ploeh.AutoFixture.AutoMoq.dll
--------------------------------------------------------------------------------
/lib/AutoFixture/Ploeh.SemanticComparison.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/AutoFixture/Ploeh.SemanticComparison.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/1.0/NDoc.Documenter.Msdn.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/1.0/NDoc.Documenter.Msdn.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/1.0/nunit-console-runner.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/1.0/nunit-console-runner.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/net/2.0/NDoc.Documenter.Msdn.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/net/2.0/NDoc.Documenter.Msdn.dll
--------------------------------------------------------------------------------
/settings/SettingsFileReadMe.txt:
--------------------------------------------------------------------------------
1 | Warning!
2 | You cannot edit these settings files with Visual Studio. It believes they are something they are not.
--------------------------------------------------------------------------------
/lib/NAnt/ThoughtWorks.CruiseControl.MSBuild.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/ThoughtWorks.CruiseControl.MSBuild.dll
--------------------------------------------------------------------------------
/lib/NAnt/extensions/common/2.0/NAnt.MSBuild.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/extensions/common/2.0/NAnt.MSBuild.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/1.1/nunit-console-runner.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/1.1/nunit-console-runner.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/2.0/nunit-console-runner.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/2.0/nunit-console-runner.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/neutral/NDoc.ExtendedUI.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/neutral/NDoc.ExtendedUI.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/mono/2.0/NDoc.Documenter.Msdn.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/mono/2.0/NDoc.Documenter.Msdn.dll
--------------------------------------------------------------------------------
/lib/NCover/ActiproSoftware.WinUICore.Net11.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/ActiproSoftware.WinUICore.Net11.dll
--------------------------------------------------------------------------------
/lib/ReportGenerator/ICSharpCode.NRefactory.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/ReportGenerator/ICSharpCode.NRefactory.dll
--------------------------------------------------------------------------------
/lib/NCover/ActiproSoftware.SyntaxEditor.Net11.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NCover/ActiproSoftware.SyntaxEditor.Net11.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/neutral/NDoc.Documenter.Msdn.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/neutral/NDoc.Documenter.Msdn.dll
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/CallStateChanged.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class CallStateChanged : StateChanged
4 | { }
5 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/PlayerCompleted.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class PlayerCompleted : StateChanged
4 | { }
5 | }
6 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/StreamDestroyed.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class StreamDestroyed : StateChanged
4 | { }
5 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Interfaces/IConfigureApi.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Interfaces
2 | {
3 | public interface IConfigureApi : IConfigureComponents
4 | { }
5 | }
--------------------------------------------------------------------------------
/uppercutbuild.rb:
--------------------------------------------------------------------------------
1 | require 'uppercut/cli'
2 | require 'uppercut/loader'
3 | require 'uppercut/config'
4 | require 'uppercut/project'
5 |
6 | #other fancy stuff
7 |
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/neutral/ICSharpCode.SharpCvsLib.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/neutral/ICSharpCode.SharpCvsLib.dll
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/neutral/ICSharpCode.SharpZipLib.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/neutral/ICSharpCode.SharpZipLib.dll
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/BuddyStateChanged.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class BuddyStateChanged : StateChanged
4 | { }
5 | }
--------------------------------------------------------------------------------
/pjsip.Interop/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/CallMediaStateChanged.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class CallMediaStateChanged : StateChanged
4 | { }
5 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IObjectFactory.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Interfaces
2 | {
3 | public interface IObjectFactory
4 | {
5 | T Create();
6 | }
7 | }
--------------------------------------------------------------------------------
/Tests/Integration/pjsip4net.Console/ICommand.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Console
2 | {
3 | public interface ICommand
4 | {
5 | void Execute();
6 | }
7 | }
--------------------------------------------------------------------------------
/lib/NAnt/lib/common/neutral/ICSharpCode.SharpCvsLib.Console.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/lib/NAnt/lib/common/neutral/ICSharpCode.SharpCvsLib.Console.dll
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/RegistrationStateChanged.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class RegistrationStateChanged : StateChanged
4 | { }
5 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/StateChanged.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class StateChanged
4 | {
5 | public int Id { get; set; }
6 | }
7 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/BuddyActivity.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public enum BuddyActivity
4 | {
5 | Unknown,
6 | Away,
7 | Busy,
8 | }
9 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/BuddyStatus.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public enum BuddyStatus
4 | {
5 | Unknown,
6 | Online,
7 | Offline,
8 | }
9 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/TransportType.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core
2 | {
3 | public enum TransportType
4 | {
5 | Udp = 17,
6 | Tcp = 6,
7 | Tls = 255
8 | }
9 | }
--------------------------------------------------------------------------------
/Tests/Integration/pjsip4net.Console/ICommandFactory.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Console
2 | {
3 | public interface ICommandFactory
4 | {
5 | ICommand Create(string cmd);
6 | }
7 | }
--------------------------------------------------------------------------------
/deployment/templates/AppDeployment.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 |
3 | SET DIR=%~d0%~p0%
4 |
5 | SET file.settings="%DIR%..\settings\${environment}.settings"
6 |
7 | ::your deployment settings here
8 |
9 | pause
--------------------------------------------------------------------------------
/lib/NCover/NCover.Console.exe.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/DtmfRecieved.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class DtmfRecieved : StateChanged
4 | {
5 | public int Digit { get; set; }
6 | }
7 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/SrtpRequirement.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public enum SrtpRequirement
4 | {
5 | Disabled,
6 | Optional,
7 | Mandatory,
8 | }
9 | }
--------------------------------------------------------------------------------
/Tests/Integration/pjsip4net.Console/NeroSoundTrax_test8_PCM_Mono_VBR_16SS_48000Hz.wav:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ladendirekt/pjsip4net/HEAD/Tests/Integration/pjsip4net.Console/NeroSoundTrax_test8_PCM_Mono_VBR_16SS_48000Hz.wav
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/BuddyConfig.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public class BuddyConfig
4 | {
5 | public string Uri { get; set; }
6 | public bool Subscribe { get; set; }
7 | }
8 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/RedirectOption.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public enum RedirectOption
4 | {
5 | Reject,
6 | Accept,
7 | Pending,
8 | Stop,
9 | }
10 | }
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | [assembly: Guid("4573b3a7-e447-44c6-86b1-b5cc8eddd4a4")]
6 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/LogRequested.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class LogRequested
4 | {
5 | public int Level { get; set; }
6 | public string Message { get; set; }
7 | }
8 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/SipRole.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public enum SipRole
4 | {
5 | RoleUac,
6 | RoleUas,
7 | UacRole = RoleUac,
8 | UasRole = RoleUas,
9 | }
10 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/IncomingCallRecieved.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class IncomingCallRecieved
4 | {
5 | public int AccountId { get; set; }
6 | public int CallId { get; set; }
7 | }
8 | }
--------------------------------------------------------------------------------
/pjsip4net/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/pjsip.Interop/Services/SoundDeviceInfoConverter.cs:
--------------------------------------------------------------------------------
1 | using AutoMapper;
2 |
3 | namespace pjsip.Interop.Services
4 | {
5 | //public class SoundDeviceInfoConverter : ITypeConverter
6 | //{
7 |
8 | //}
9 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/MediaDirection.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public enum MediaDirection
4 | {
5 | None = 0,
6 | Encoding = 1,
7 | Decoding = 2,
8 | EncodingDecoding = 3,
9 | }
10 | }
--------------------------------------------------------------------------------
/pjsip4net.Container.Castle/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/CallRedirected.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class CallRedirected : StateChanged
4 | {
5 | public string Target { get; set; }
6 | public RedirectOption Option { get; set; }
7 | }
8 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/TransportFlags.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net.Core.Data
4 | {
5 | [Flags]
6 | public enum TransportFlags
7 | {
8 | Reliable = 1,
9 | Secure = 2,
10 | Datagram = 4,
11 | }
12 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/CallMediaState.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public enum CallMediaState
4 | {
5 | None,
6 | Active,
7 | LocalHold,
8 | RemoteHold,
9 | Error,
10 | Disconnected,
11 | }
12 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Interfaces/IResource.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Interfaces
2 | {
3 | ///
4 | /// Disposable object abstraction.
5 | ///
6 | internal interface IResource
7 | {
8 | void InternalDispose();
9 | }
10 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/CallTransferRequested.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class CallTransferRequested : StateChanged
4 | {
5 | public string Destination { get; set; }
6 | public SipStatusCode Status { get; set; }
7 | }
8 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/LoggingConfig.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public class LoggingConfig
4 | {
5 | public bool LogMessages { get; set; }
6 | public uint LogLevel { get; set; }
7 | public bool TraceAndDebug { get; set; }
8 | }
9 | }
--------------------------------------------------------------------------------
/lib/NCover/NCoverExplorer.exe.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/InviteState.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public enum InviteState
4 | {
5 | None,
6 | Calling,
7 | Incoming,
8 | Early,
9 | Connecting,
10 | Confirmed,
11 | Disconnected
12 | }
13 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/SubscriptionState.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public enum SubscriptionState
4 | {
5 | Null,
6 | Sent,
7 | Accepted,
8 | Pending,
9 | Active,
10 | Terminated,
11 | Unknown,
12 | }
13 | }
--------------------------------------------------------------------------------
/Tests/pjsip4net.Testing/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // The following GUID is for the ID of the typelib if this project is exposed to COM
6 | [assembly: Guid("8cac3f94-d150-4854-9753-49f35989d974")]
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IWavRecorder.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Interfaces;
3 |
4 | namespace pjsip4net.Interfaces
5 | {
6 | public interface IWavRecorder : IFileSourceMedia, IIdentifiable, IDisposable
7 | {
8 | void Start(string fileName);
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/pjsip4net.Container.Castle/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 | // The following GUID is for the ID of the typelib if this project is exposed to COM
5 | [assembly: Guid("74bd7c62-80d4-42df-a67b-3b16bfc1a608")]
6 |
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IFileSourceMedia.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Data;
2 |
3 | namespace pjsip4net.Interfaces
4 | {
5 | public interface IFileSourceMedia
6 | {
7 | string File { get; }
8 | int ConferencePortId { get; }
9 | ConferencePortInfo ConferenceSlot { get; }
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Interfaces/IConfigureComponents.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Interfaces
2 | {
3 | ///
4 | /// An abstraction of services configurator.
5 | ///
6 | public interface IConfigureComponents
7 | {
8 | void Configure(IContainer container);
9 | }
10 | }
--------------------------------------------------------------------------------
/open.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 | # stty -echo
3 |
4 | # ::Project UppercuT - http://uppercut.googlecode.com
5 | # ::No edits to this file are required - http://uppercut.pbwiki.com
6 |
7 | mono ./lib/NAnt/NAnt.exe $1 /f:$(cd $(dirname "$0"); pwd)/build/open.build -D:build.config.settings=$(cd $(dirname "$0"); pwd)/Settings/UppercuT.config
8 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/NatDetected.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class NatDetected
4 | {
5 | public int Status { get; set; }
6 | public string StatusText { get; set; }
7 | public NatType NatType { get; set; }
8 | public string NatName { get; set; }
9 | }
10 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Interfaces/IConfigurationProvider.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Interfaces
2 | {
3 | ///
4 | /// An abstraction for external configuration provider.
5 | ///
6 | public interface IConfigurationProvider
7 | {
8 | void Configure(IConfigurationContext context);
9 | }
10 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/NatType.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public enum NatType
4 | {
5 | Unknown,
6 | ErrUnknown,
7 | Open,
8 | Blocked,
9 | SymmetricUdp,
10 | FullCone,
11 | Symmetric,
12 | Restricted,
13 | PortRestricted,
14 | }
15 | }
--------------------------------------------------------------------------------
/zip.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 | # stty -echo
3 |
4 | # ::Project UppercuT - http://uppercut.googlecode.com
5 | # ::No edits to this file are required - http://uppercut.pbwiki.com
6 |
7 | ./build.sh
8 |
9 | mono ./lib/NAnt/NAnt.exe $1 /f:$(cd $(dirname "$0"); pwd)/build/zip.build -D:build.config.settings=$(cd $(dirname "$0"); pwd)/Settings/UppercuT.config
10 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/ImStatusChanged.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class ImStatusChanged : StateChanged
4 | {
5 | public string To { get; set; }
6 | public string Body { get; set; }
7 | public SipStatusCode Status { get; set; }
8 | public string Reason { get; set; }
9 | }
10 | }
--------------------------------------------------------------------------------
/Tests/pjsip4net.Testing/ConfigureForTest.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Configuration;
2 |
3 | namespace pjsip4net.Testing
4 | {
5 | public static class ConfigureForTest
6 | {
7 | public static Configure WithVersion_For_Tests(this Configure configure)
8 | {
9 | return configure.With(new TestConfigurator());
10 | }
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/CallTransferStatusChanged.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class CallTransferStatusChanged : StateChanged
4 | {
5 | public int Status { get; set; }
6 | public string StatusText { get; set; }
7 | public bool Final { get; set; }
8 | public bool Continue { get; set; }
9 | }
10 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Interfaces/IEventsProvider.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net.Core.Interfaces
4 | {
5 | public interface IEventsProvider
6 | {
7 | void Publish(T @event) where T : class;
8 | void Subscribe(Action actOnEvent) where T : class;
9 | IDisposable SubscribeTemporarilly(Action actOnEvent) where T : class;
10 | }
11 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/CallRedirectedEventArgs.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Data;
3 |
4 | namespace pjsip4net.Calls
5 | {
6 | public class CallRedirectedEventArgs : EventArgs
7 | {
8 | public int CallId { get; internal set; }
9 | public string Target { get; internal set; }
10 | public RedirectOption Option { get; set; }
11 | }
12 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IMediaSource.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 |
6 | namespace pjsip4net.Interfaces
7 | {
8 | public interface IMediaSource
9 | {
10 | double RxLevel { get; set; }
11 | double TxLevel { get; set; }
12 |
13 | void RecordTo(string fileName);
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Utils/ValidFileNameTemplate.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Utils
2 | {
3 | public static class ValidFileNameTemplate
4 | {
5 | public static bool Check(string fileName)
6 | {
7 | Helper.GuardNotNullStr(fileName);
8 | Helper.GuardIsTrue(fileName.EndsWith(".wav"));
9 | return true;
10 | }
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/IncomingTypingRecieved.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class IncomingTypingRecieved
4 | {
5 | public int CallId { get; set; }
6 | public string From { get; set; }
7 | public string To { get; set; }
8 | public string Contact { get; set; }
9 | public bool IsTyping { get; set; }
10 | }
11 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IVoIPTransportFactory.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core;
2 | using pjsip4net.Core.Data;
3 |
4 | namespace pjsip4net.Interfaces
5 | {
6 | internal interface IVoIPTransportFactory
7 | {
8 | IVoIPTransport CreateTransport(TransportType transportType);
9 | IVoIPTransport CreateTransport(TransportType transportType, TransportConfig config);
10 | }
11 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Configuration/CoreComponentConfigurator.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Interfaces;
2 |
3 | namespace pjsip4net.Core.Configuration
4 | {
5 | public class CoreComponentConfigurator : IConfigureComponents
6 | {
7 | public void Configure(IContainer container)
8 | {
9 | container.RegisterAsSingleton();
10 | }
11 | }
12 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/RpidElement.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public class RpidElement
4 | {
5 | public string Id { get; set; }
6 | public RpidActivity Activity { get; set; }
7 | public string Note { get; set; }
8 | }
9 |
10 | public enum RpidActivity
11 | {
12 | Unknown,
13 | Away,
14 | Busy,
15 | }
16 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/IncomingCallEventArgs.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net.Calls
4 | {
5 | public class IncomingCallEventArgs : EventArgs
6 | {
7 | public IncomingCallEventArgs(string from)
8 | {
9 | From = from;
10 | }
11 |
12 | public string From { get; private set; }
13 | public bool Accept { get; set; }
14 | }
15 | }
--------------------------------------------------------------------------------
/pjsip4net/Configuration/ConfigureFromConfig.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Configuration;
2 |
3 | namespace pjsip4net.Configuration
4 | {
5 | public static class ConfigureFromConfig
6 | {
7 | public static Configure FromConfig(this Configure cfg)
8 | {
9 | cfg.With(new CfgFileConfigurationProvider());
10 | return cfg;
11 | }
12 | }
13 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IWavPlayer.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Interfaces;
3 |
4 | namespace pjsip4net.Interfaces
5 | {
6 | public interface IWavPlayer : IFileSourceMedia, IIdentifiable, IDisposable
7 | {
8 | void Start(string file, bool loop);
9 | void SetPosition(uint position);
10 | event EventHandler Completed;
11 | }
12 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/ICallBuilder.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Interfaces
2 | {
3 | public interface ICallBuilder
4 | {
5 | ICallBuilder To(string extension);
6 | ICallBuilder At(string domain);
7 | ICallBuilder Through(string port);
8 | ICallBuilder From(IAccount account);
9 | ICallBuilder RecordTo(string fileName);
10 | ICall Call();
11 | }
12 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/IncomingSubscribeRecieved.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class IncomingSubscribeRecieved
4 | {
5 | public int AccountId { get; set; }
6 | public int BuddyId { get; set; }
7 | public string From { get; set; }
8 | public SipStatusCode Status { get; set; }
9 | public string Reason { get; set; }
10 | }
11 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/CallTransferEventArgs.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Interfaces;
4 |
5 | namespace pjsip4net.Calls
6 | {
7 | public class CallTransferEventArgs : EventArgs
8 | {
9 | public string Destination { get; internal set; }
10 | public SipStatusCode StatusCode { get; set; }
11 | public ICall Call { get; internal set; }
12 | }
13 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 | [assembly: Guid("377f8604-e60b-4915-806e-378ae912ed0d")]
5 | [assembly: InternalsVisibleTo("pjsip4net")]
6 | [assembly: InternalsVisibleTo("pjsip4net.Tests")]
7 | [assembly: InternalsVisibleTo("DynamicProxyGenAssembly2")]
8 | [assembly: InternalsVisibleTo("Ploeh.AutoFixture")]
9 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Utils/EventArgs.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net.Core.Utils
4 | {
5 | public class EventArgs : EventArgs
6 | {
7 | public EventArgs()
8 | {
9 | }
10 |
11 | public EventArgs(T data)
12 | {
13 | Helper.GuardNotNull(data);
14 | Data = data;
15 | }
16 |
17 | public T Data { get; set; }
18 | }
19 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Utils/Tuple.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Utils
2 | {
3 | public class Tuple
4 | {
5 | public Tuple()
6 | { }
7 |
8 | public Tuple(T1 part1, T2 part2)
9 | {
10 | Part1 = part1;
11 | Part2 = part2;
12 | }
13 |
14 | public T1 Part1 { get; private set; }
15 | public T2 Part2 { get; private set; }
16 | }
17 | }
--------------------------------------------------------------------------------
/pjsip4net/Transport/TcpTransport.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core;
2 | using pjsip4net.Core.Interfaces.ApiProviders;
3 |
4 | namespace pjsip4net.Transport
5 | {
6 | internal class TcpTransport : VoIPTransport
7 | {
8 | public TcpTransport(ITransportApiProvider transportApiProvider)
9 | : base(transportApiProvider)
10 | {
11 | _transportType = TransportType.Tcp;
12 | }
13 | }
14 | }
--------------------------------------------------------------------------------
/pjsip4net/Transport/UdpTransport.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core;
2 | using pjsip4net.Core.Interfaces.ApiProviders;
3 |
4 | namespace pjsip4net.Transport
5 | {
6 | internal class UdpTransport : VoIPTransport
7 | {
8 | public UdpTransport(ITransportApiProvider transportApiProvider)
9 | : base(transportApiProvider)
10 | {
11 | _transportType = TransportType.Udp;
12 | }
13 | }
14 | }
--------------------------------------------------------------------------------
/pjsip4net/TypingEventArgs.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net
2 | {
3 | public class TypingEventArgs : PagerEventArgs
4 | {
5 | public TypingEventArgs(string from, string to, string contact, int callId, bool isTyping)
6 | : base(from, to, contact, null, callId, null)
7 | {
8 | IsTyping = isTyping;
9 | }
10 |
11 | public bool IsTyping { get; private set; }
12 | }
13 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/Events/IncomingImRecieved.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data.Events
2 | {
3 | public class IncomingImRecieved
4 | {
5 | public int CallId { get; set; }
6 | public string From { get; set; }
7 | public string To { get; set; }
8 | public string Contact { get; set; }
9 | public string MimeType { get; set; }
10 | public string Body { get; set; }
11 | }
12 | }
--------------------------------------------------------------------------------
/open.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 |
3 | ::Project UppercuT - http://uppercut.googlecode.com
4 | ::No edits to this file are required - http://uppercut.pbwiki.com
5 |
6 | SET DIR=%cd%
7 | SET BUILD_DIR=%~d0%~p0%
8 | SET NANT="%BUILD_DIR%lib\Nant\nant.exe"
9 | SET build.config.settings="%DIR%\settings\UppercuT.config"
10 |
11 | %NANT% -logger:NAnt.Core.DefaultLogger -quiet /f:%BUILD_DIR%build\open.build -D:build.config.settings=%build.config.settings%
--------------------------------------------------------------------------------
/pjsip4net.Core/Configuration/ConfigureContainer.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Interfaces;
2 | using pjsip4net.Core.Utils;
3 |
4 | namespace pjsip4net.Core.Configuration
5 | {
6 | public static class ConfigureContainer
7 | {
8 | public static void Set(IContainer container, Configure config)
9 | {
10 | Helper.GuardNotNull(container);
11 | config.Container = container;
12 | }
13 | }
14 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IBuddyBuilder.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core;
2 |
3 | namespace pjsip4net.Interfaces
4 | {
5 | public interface IBuddyBuilder
6 | {
7 | IBuddyBuilder WithName(string name);
8 | IBuddyBuilder Through(string port);
9 | IBuddyBuilder At(string domain);
10 | IBuddyBuilder Via(TransportType transport);
11 | IBuddyBuilder Subscribing();
12 | IBuddy Register();
13 | }
14 | }
--------------------------------------------------------------------------------
/pjsip4net/Accounts/AccountStateChangedEventArgs.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Data;
3 |
4 | namespace pjsip4net.Accounts
5 | {
6 | public class AccountStateChangedEventArgs : EventArgs
7 | {
8 | public int Id { get; internal set; }
9 | public string Uri { get; internal set; }
10 | public string StatusText { get; internal set; }
11 | public SipStatusCode StatusCode { get; internal set; }
12 | }
13 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/TransportConfig.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public class TransportConfig
4 | {
5 | public uint Port { get; set; }
6 | public string PublicAddress { get; set; }
7 | public string BoundAddress { get; set; }
8 | public TlsConfig TlsSetting { get; set; }
9 |
10 | public TransportConfig()
11 | {
12 | TlsSetting = new TlsConfig();
13 | }
14 | }
15 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/ITlsTransport.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Interfaces;
2 |
3 | namespace pjsip4net.Interfaces
4 | {
5 | public interface ITlsTransport : IVoIPTransport
6 | {
7 | string CAListFile { get; set; }
8 | string CertificateFile { get; set; }
9 | string PrivateKeyFile { get; set; }
10 | bool VerifyServer { get; set; }
11 | bool VerifyClient { get; set; }
12 | bool RequireClientCertificate { get; set; }
13 | }
14 | }
--------------------------------------------------------------------------------
/pjsip4net/IM/BuddyStateChangedEventArgs.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Data;
3 |
4 | namespace pjsip4net.IM
5 | {
6 | public class BuddyStateChangedEventArgs : EventArgs
7 | {
8 | public int Id { get; internal set; }
9 | public string Uri { get; internal set; }
10 | public string StatusText { get; internal set; }
11 | public BuddyStatus Status { get; internal set; }
12 | public string Note { get; internal set; }
13 | }
14 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Interfaces/IIdentifiable.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Utils;
3 |
4 | namespace pjsip4net.Core.Interfaces
5 | {
6 | ///
7 | /// An interface that provides comparison template method for
8 | ///
9 | ///
10 | public interface IIdentifiable : IEquatable>
11 | {
12 | int Id { get; }
13 | bool DataEquals(T other);
14 | }
15 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Utils/AbstractState.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Utils
2 | {
3 | public abstract class AbstractState
4 | {
5 | public abstract void StateChanged();
6 | }
7 |
8 | public abstract class AbstractState : AbstractState where T : StateMachine
9 | {
10 | protected T _context;
11 |
12 | protected AbstractState(T owner)
13 | {
14 | Helper.GuardNotNull(owner);
15 | _context = owner;
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/lib/MoMA/Reports/Media/moma.js:
--------------------------------------------------------------------------------
1 | function toggle (name, img)
2 | {
3 | var element = document.getElementById (name);
4 |
5 | if (element.style.display == 'none')
6 | element.style.display = '';
7 | else
8 | element.style.display = 'none';
9 |
10 | var img_element = document.getElementById (img);
11 |
12 | if (img_element.src.indexOf ('minus.png') > 0)
13 | img_element.src = 'Media/plus.png';
14 | else
15 | img_element.src = 'Media/minus.png';
16 | }
17 |
18 |
--------------------------------------------------------------------------------
/pjsip4net.Core/PjsipErrorException.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net.Core
4 | {
5 | public class PjsipErrorException : Exception
6 | {
7 | public PjsipErrorException(int code)
8 | : this(code, "")
9 | {
10 | }
11 |
12 | public PjsipErrorException(int code, string message)
13 | : base(message)
14 | {
15 | ErrorCode = code;
16 | }
17 |
18 | public int ErrorCode { get; private set; }
19 | }
20 | }
--------------------------------------------------------------------------------
/license.txt:
--------------------------------------------------------------------------------
1 | Copyright RobertT. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
--------------------------------------------------------------------------------
/pjsip4net/Calls/CallStateChangedEventArgs.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Data;
3 |
4 | namespace pjsip4net.Calls
5 | {
6 | public class CallStateChangedEventArgs : EventArgs
7 | {
8 | public int Id { get; internal set; }
9 | public string DestinationUri { get; internal set; }
10 | public TimeSpan Duration { get; internal set; }
11 | public InviteState InviteState { get; internal set; }
12 | public CallMediaState MediaState { get; internal set; }
13 | }
14 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/SignalLevel.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public struct SignalLevel
4 | {
5 | private uint _rx;
6 | public uint Rx
7 | {
8 | get { return _rx; }
9 | }
10 |
11 | private uint _tx;
12 | public uint Tx
13 | {
14 | get { return _tx; }
15 | }
16 |
17 | public SignalLevel(uint rx, uint tx)
18 | {
19 | _rx = rx;
20 | _tx = tx;
21 | }
22 | }
23 | }
--------------------------------------------------------------------------------
/pjsip4net/LogEventArgs.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Utils;
3 |
4 | namespace pjsip4net
5 | {
6 | public class LogEventArgs : EventArgs
7 | {
8 | public LogEventArgs(int level, string data)
9 | {
10 | Helper.GuardPositiveInt(level);
11 | Helper.GuardNotNullStr(data);
12 | Level = level;
13 | Data = data;
14 | }
15 |
16 | public int Level { get; private set; }
17 | public string Data { get; private set; }
18 | }
19 | }
--------------------------------------------------------------------------------
/pjsip4net/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 |
6 | // The following GUID is for the ID of the typelib if this project is exposed to COM
7 |
8 | [assembly: Guid("bf2d42a4-d68e-4e38-9fa7-d175270e9b80")]
9 |
10 | [assembly: InternalsVisibleTo("pjsip4net.Tests, PublicKeyToken=null", AllInternalsVisible = true)]
11 | [assembly: InternalsVisibleTo("Ploeh.AutoFixture")]
12 | [assembly: InternalsVisibleTo("DynamicProxyGenAssembly2")]
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/TransportInfo.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public class TransportInfo
4 | {
5 | public int Id { get; set; }
6 | public TransportType Type { get; set; }
7 | public string TypeName { get; set; }
8 | public string Info { get; set; }
9 | public uint Flag { get; set; }
10 | public uint AddrLen { get; set; }
11 | public string Host { get; set; }
12 | public int Port { get; set; }
13 | public uint UsageCount { get; set; }
14 | }
15 | }
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/App.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/_base.cs:
--------------------------------------------------------------------------------
1 | using NUnit.Framework;
2 | using Ploeh.AutoFixture;
3 | using Ploeh.AutoFixture.AutoMoq;
4 |
5 | namespace pjsip4net.Tests
6 | {
7 | public class _base
8 | {
9 | protected IFixture _fixture;
10 |
11 | [SetUp]
12 | public virtual void Setup()
13 | {
14 | _fixture = new Fixture().Customize(new AutoMoqCustomization());
15 | }
16 |
17 | [TearDown]
18 | public virtual void Teardown()
19 | {
20 | _fixture = null;
21 | }
22 | }
23 | }
--------------------------------------------------------------------------------
/pjsip4net/Configuration/DefaultTransportComponentConfigurator.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Interfaces;
2 | using pjsip4net.Core.Utils;
3 | using pjsip4net.Interfaces;
4 | using pjsip4net.Transport;
5 |
6 | namespace pjsip4net.Configuration
7 | {
8 | public class DefaultTransportComponentConfigurator : IConfigureComponents
9 | {
10 | public void Configure(IContainer container)
11 | {
12 | Helper.GuardNotNull(container);
13 | container.RegisterAsSingleton();
14 | }
15 | }
16 | }
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/pjsip4net.Tests.csproj.user:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | ProjectFiles
5 |
6 |
7 |
8 |
9 |
10 |
11 | en-US
12 | false
13 |
14 |
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/Calls/CallCustomization.cs:
--------------------------------------------------------------------------------
1 | using Moq;
2 | using pjsip4net.Calls;
3 | using pjsip4net.Interfaces;
4 | using Ploeh.AutoFixture;
5 |
6 | namespace pjsip4net.Tests.Calls
7 | {
8 | public class CallCustomization : ICustomization
9 | {
10 | public void Customize(IFixture fixture)
11 | {
12 | fixture.Customize(x => x.OmitAutoProperties());
13 | fixture.Freeze>();
14 | var call = fixture.Freeze>();
15 | fixture.Register(() => call.Object);
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/deployment/templates/DBDeployment.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 |
3 | SET DIR=%~d0%~p0%
4 |
5 | SET database.name="${database.name}"
6 | SET sql.files.directory="${dirs.db}"
7 | SET backup.file="${restore.from.path}"
8 | SET server.database="${server.database}"
9 | SET repository.path="${repository.path}"
10 | SET version.file="_BuildInfo.xml"
11 | SET version.xpath="//buildInfo/version"
12 | SET environment="${environment}"
13 |
14 | "%DIR%rh\rh.exe" /d=%database.name% /f=%sql.files.directory% /s=%server.database% /vf=%version.file% /vx=%version.xpath% /r=%repository.path% /env=%environment% /simple
15 |
16 | pause
--------------------------------------------------------------------------------
/lib/NCover/VC80CRT.MAN:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Container/ContainerException.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net.Core.Container
4 | {
5 | ///
6 | /// Exception that is thrown by dependency injection container.
7 | ///
8 | public class ContainerException : Exception
9 | {
10 | public ContainerException()
11 | { }
12 |
13 | public ContainerException(string message) : base(message)
14 | { }
15 |
16 | public ContainerException(string message, Exception inner) : base(message, inner)
17 | { }
18 | }
19 | }
--------------------------------------------------------------------------------
/lib/NUnit/agent.log.conf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/lib/NUnit/launcher.log.conf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/pjsip4net/NatEventArgs.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Data.Events;
4 |
5 | namespace pjsip4net
6 | {
7 | public class NatEventArgs : EventArgs
8 | {
9 | internal NatEventArgs(NatDetected result)
10 | {
11 | StatusText = result.StatusText;
12 | NatType = result.NatType;
13 | NatTypeName = result.NatName;
14 | }
15 |
16 | public string StatusText { get; set; }
17 | public NatType NatType { get; set; }
18 | public string NatTypeName { get; set; }
19 | }
20 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/DtmfEventArgs.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Utils;
3 | using pjsip4net.Interfaces;
4 |
5 | namespace pjsip4net.Calls
6 | {
7 | public class DtmfEventArgs : EventArgs
8 | {
9 | public DtmfEventArgs(ICall call, int digit)
10 | {
11 | Helper.GuardNotNull(call);
12 | Helper.GuardPositiveInt(call.Id);
13 |
14 | Digit = Convert.ToChar(digit);
15 | CallId = call.Id;
16 | }
17 |
18 | public char Digit { get; private set; }
19 | public int CallId { get; private set; }
20 | }
21 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IMessageBuilder.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Accounts;
2 | using pjsip4net.Calls;
3 |
4 | namespace pjsip4net.Interfaces
5 | {
6 | public interface IMessageBuilder
7 | {
8 | IMessageBuilder To(string extension);
9 | IMessageBuilder At(string domain);
10 | IMessageBuilder Through(string port);
11 | IMessageBuilder WithBody(string body);
12 | IMessageBuilder From(IAccount account);
13 | IMessageBuilder InDialogOf(ICall call);
14 | void Send();
15 | void SendTyping();
16 | void SendFinishedTyping();
17 | }
18 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Utils/StringBuilderExtension.cs:
--------------------------------------------------------------------------------
1 | using System.Text;
2 |
3 | namespace pjsip4net.Core.Utils
4 | {
5 | public static class StringBuilderExtension
6 | {
7 | public static void Clear(this StringBuilder builder)
8 | {
9 | if (builder.Length > 0)
10 | builder.Remove(0, builder.Length);
11 | }
12 |
13 | public static string ToStringAndClear(this StringBuilder builder)
14 | {
15 | string result = builder.ToString();
16 | builder.Clear();
17 | return result;
18 | }
19 | }
20 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/AccountInfo.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public class AccountInfo
4 | {
5 | public int Id { get; set; }
6 | public int IsDefault { get; set; }
7 | public string AccUri{ get; set; }
8 | public int HasRegistration{ get; set; }
9 | public int Expires{ get; set; }
10 | public SipStatusCode Status{ get; set; }
11 | public string StatusText{ get; set; }
12 | public int OnlineStatus{ get; set; }
13 | public string OnlineStatusText{ get; set; }
14 | public RpidElement Rpid{ get; set; }
15 | }
16 | }
--------------------------------------------------------------------------------
/pjsip.Interop/ConfigureVersion_1_4.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Configuration;
2 |
3 | namespace pjsip.Interop
4 | {
5 | ///
6 | /// This configurator registers services that enable access to underlying pjsip 1.4 library pjsua API.
7 | ///
8 | public static class ConfigureVersion_1_4
9 | {
10 | ///
11 | /// Configure with pjsip version 1.4.
12 | ///
13 | public static Configure WithVersion_1_4(this Configure cfg)
14 | {
15 | return cfg.With(new Version_1_4_ComponentConfigurator());
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/deployment/templates/DBDeployment.RESTORE.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 |
3 | SET DIR=%~d0%~p0%
4 |
5 | SET database.name="${database.name}"
6 | SET sql.files.directory="${dirs.db}"
7 | SET backup.file="${restore.from.path}"
8 | SET server.database="${server.database}"
9 | SET repository.path="${repository.path}"
10 | SET version.file="_BuildInfo.xml"
11 | SET version.xpath="//buildInfo/version"
12 | SET environment="${environment}"
13 |
14 | "%DIR%rh\rh.exe" /d=%database.name% /f=%sql.files.directory% /s=%server.database% /vf=%version.file% /vx=%version.xpath% /r=%repository.path% /env=%environment% /simple /restore /rfp=%backup.file% /rt=1200
15 |
16 | pause
--------------------------------------------------------------------------------
/pjsip4net.Core/DelegatingConsumer.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Magnum.Pipeline;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Core
6 | {
7 | public class DelegatingConsumer : IConsumer where T : class
8 | {
9 | private readonly Action _action;
10 |
11 | public DelegatingConsumer(Action action)
12 | {
13 | Helper.GuardNotNull(action);
14 | _action = action;
15 | }
16 |
17 | #region Implementation of IConsumer
18 |
19 | public void Consume(T message)
20 | {
21 | _action(message);
22 | }
23 |
24 | #endregion
25 | }
26 | }
--------------------------------------------------------------------------------
/pjsip.Interop/Services/Pjsip4net2PjsuaProfile.cs:
--------------------------------------------------------------------------------
1 | using AutoMapper;
2 |
3 | namespace pjsip.Interop.Services
4 | {
5 | public class Pjsip4net2PjsuaProfile : Profile
6 | {
7 | protected override void Configure()
8 | {
9 | base.Configure();
10 | SourceMemberNamingConvention = new PascalCaseNamingConvention();
11 | DestinationMemberNamingConvention = new LowerUnderscoreNamingConvention();
12 | }
13 |
14 | public override string ProfileName
15 | {
16 | get
17 | {
18 | return "pjsip4net2pjsua";
19 | }
20 | }
21 | }
22 | }
--------------------------------------------------------------------------------
/pjsip.Interop/Services/Pjsua2Pjsip4netProfile.cs:
--------------------------------------------------------------------------------
1 | using AutoMapper;
2 |
3 | namespace pjsip.Interop.Services
4 | {
5 | public class Pjsua2Pjsip4netProfile : Profile
6 | {
7 | protected override void Configure()
8 | {
9 | base.Configure();
10 | SourceMemberNamingConvention = new LowerUnderscoreNamingConvention();
11 | DestinationMemberNamingConvention = new PascalCaseNamingConvention();
12 | }
13 |
14 | public override string ProfileName
15 | {
16 | get
17 | {
18 | return "pjsua2pjsip4net";
19 | }
20 | }
21 | }
22 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IBuddy.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Data;
2 | using pjsip4net.Core.Interfaces;
3 | using pjsip4net.IM;
4 |
5 | namespace pjsip4net.Interfaces
6 | {
7 | public interface IBuddy : IInitializable
8 | {
9 | int Id { get; }
10 | string Uri { get; set; }
11 | bool Subscribe { get; set; }
12 | string Contact { get; }
13 | BuddyStatus Status { get; }
14 | string StatusText { get; }
15 | bool MonitoringPresence { get; }
16 | BuddyActivity Activity { get; }
17 | string ActivityNote { get; }
18 | void UpdatePresenceState();
19 | void Unregister();
20 | }
21 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Utils/ValueWrapper.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Utils
2 | {
3 | internal class ValueWrapper
4 | where T : struct
5 | {
6 | public ValueWrapper(T value)
7 | {
8 | Value = value;
9 | }
10 |
11 | public T Value { get; private set; }
12 |
13 | public override bool Equals(object obj)
14 | {
15 | if (!(obj is ValueWrapper)) return false;
16 | return Value.Equals(((ValueWrapper) obj).Value);
17 | }
18 |
19 | public override int GetHashCode()
20 | {
21 | return Value.GetHashCode();
22 | }
23 | }
24 | }
--------------------------------------------------------------------------------
/pjsip4net/DefaultObjectFactory.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Interfaces;
2 | using pjsip4net.Core.Utils;
3 | using pjsip4net.Interfaces;
4 |
5 | namespace pjsip4net
6 | {
7 | public class DefaultObjectFactory : IObjectFactory
8 | {
9 | private IContainer _container;
10 |
11 | public DefaultObjectFactory(IContainer container)
12 | {
13 | Helper.GuardNotNull(container);
14 | _container = container;
15 | }
16 |
17 | #region Implementation of IObjectFactory
18 |
19 | public T Create()
20 | {
21 | return _container.Get();
22 | }
23 |
24 | #endregion
25 | }
26 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/TlsConfig.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net.Core.Data
4 | {
5 | public class TlsConfig
6 | {
7 | public string CAListFile {get; set; }
8 | public string CertFile {get; set; }
9 | public string PrivKeyFile {get; set; }
10 | public string Password {get; set; }
11 | public int Method {get; set; }
12 | public string Ciphers {get; set; }
13 | public string ServerName {get; set; }
14 | public bool VerifyServer {get; set; }
15 | public bool VerifyClient {get; set; }
16 | public bool RequireClientCert {get; set; }
17 | public TimeSpan Timeout {get; set; }
18 | }
19 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Interfaces/IConfigurationContext.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Core.Interfaces
6 | {
7 | ///
8 | /// Contextual data for external configuration provider.
9 | ///
10 | public interface IConfigurationContext
11 | {
12 | UaConfig Config { get; }
13 | LoggingConfig LoggingConfig { get; }
14 | MediaConfig MediaConfig { get; }
15 | void RegisterTransport(Utils.Tuple sipTransportConfig);
16 | void RegisterAccounts(IEnumerable accountConfigs);
17 | }
18 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/RingEventArgs.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Utils;
3 | using pjsip4net.Interfaces;
4 |
5 | namespace pjsip4net.Calls
6 | {
7 | public class RingEventArgs : EventArgs
8 | {
9 | public RingEventArgs(bool ringOn, ICall call)
10 | {
11 | Helper.GuardNotNull(call);
12 | Helper.GuardPositiveInt(call.Id);
13 | RingOn = ringOn;
14 | IsRingback = !call.IsIncoming;
15 | CallId = call.Id;
16 | }
17 |
18 | public bool RingOn { get; private set; }
19 | public bool IsRingback { get; private set; }
20 | public int CallId { get; private set; }
21 | }
22 | }
--------------------------------------------------------------------------------
/lib/NUnit/NUnitTests.nunit:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IConferenceBridge.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Interfaces
2 | {
3 | public interface IConferenceBridge
4 | {
5 | bool IsConferenceActive { get; }
6 | uint MaxPorts { get; }
7 | uint ActivePorts { get; }
8 | double? RxLevel { get; set; }
9 | double? TxLevel { get; set; }
10 |
11 | void Connect(int sourceSlot, int sinkSlot);
12 | void Interconnect(int slotX, int slotY);
13 | void Disconnect(int slotX, int slotY);
14 | void ConnectToSoundDevice(int slotId);
15 | void DisconnectFromSoundDevice(int slotId);
16 | void ConnectCall(ICall call);
17 | void DisconnectCall(ICall call);
18 | }
19 | }
--------------------------------------------------------------------------------
/zip.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 |
3 | ::Project UppercuT - http://uppercut.googlecode.com
4 | ::No edits to this file are required - http://uppercut.pbwiki.com
5 |
6 | SET DIR=%cd%
7 | SET BUILD_DIR=%~d0%~p0%
8 |
9 | ::This is gone once teamcity can call multiple files
10 | call "%BUILD_DIR%build.bat" %*
11 | if %ERRORLEVEL% NEQ 0 goto errors
12 |
13 | SET NANT="%BUILD_DIR%lib\Nant\nant.exe"
14 | SET build.config.settings="%DIR%\settings\UppercuT.config"
15 |
16 | %NANT% -logger:NAnt.Core.DefaultLogger -quiet /f:%BUILD_DIR%build\zip.build -D:build.config.settings=%build.config.settings% %*
17 |
18 | if %ERRORLEVEL% NEQ 0 goto errors
19 |
20 | goto finish
21 |
22 | :errors
23 | EXIT /B %ERRORLEVEL%
24 |
25 | :finish
--------------------------------------------------------------------------------
/Tests/Integration/pjsip4net.Console/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/pjsip4net/Configuration/DefaultCallComponentConfigurator.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Calls;
2 | using pjsip4net.Calls.Dsl;
3 | using pjsip4net.Core.Interfaces;
4 | using pjsip4net.Core.Utils;
5 | using pjsip4net.Interfaces;
6 |
7 | namespace pjsip4net.Configuration
8 | {
9 | public class DefaultCallComponentConfigurator : IConfigureComponents
10 | {
11 | public void Configure(IContainer container)
12 | {
13 | Helper.GuardNotNull(container);
14 | container.RegisterAsSingleton();
15 | container.Register();
16 | container.Register();
17 | }
18 | }
19 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Utils/TransitionFunction.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 |
4 | namespace pjsip4net.Core.Utils
5 | {
6 | public class TransitionFunction
7 | {
8 | public Q1 From { get; set; }
9 |
10 | public List TransitionSymbols { get; set; }
11 |
12 | public Q2 To { get; set; }
13 | }
14 |
15 | public class PredicateTransitionFunction : TransitionFunction
16 | {
17 | public PredicateTransitionFunction(Func predicate)
18 | {
19 | Helper.GuardNotNull(predicate);
20 | PredicateLambda = predicate;
21 | }
22 |
23 | public Func PredicateLambda { get; set; }
24 | }
25 | }
--------------------------------------------------------------------------------
/pjsip4net/Configuration/DefaultAccountComponentConfigurator.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Accounts;
2 | using pjsip4net.Accounts.Dsl;
3 | using pjsip4net.Core.Interfaces;
4 | using pjsip4net.Core.Utils;
5 | using pjsip4net.Interfaces;
6 |
7 | namespace pjsip4net.Configuration
8 | {
9 | public class DefaultAccountComponentConfigurator : IConfigureComponents
10 | {
11 | public void Configure(IContainer container)
12 | {
13 | Helper.GuardNotNull(container);
14 | container.RegisterAsSingleton();
15 | container.Register();
16 | container.Register();
17 | }
18 | }
19 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Utils/EqualsTemplate.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Interfaces;
2 |
3 | namespace pjsip4net.Core.Utils
4 | {
5 | public static class EqualsTemplate
6 | {
7 | internal static bool Equals(IIdentifiable left, IIdentifiable right)
8 | {
9 | if (ReferenceEquals(left, right)) return true;
10 | if (ReferenceEquals(left, null) || ReferenceEquals(right, null)) return false;
11 | if (typeof (T) != left.GetType() || typeof (T) != right.GetType()) return false;
12 | return left.Id == right.Id
13 | ? left.DataEquals((T) right)
14 | : left.Id.Equals(-1) && right.Id.Equals(-1) ? left.DataEquals((T) right) : false;
15 | }
16 | }
17 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IRegistry.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using pjsip4net.Core;
3 | using pjsip4net.Core.Data;
4 | using pjsip4net.Core.Interfaces;
5 | using pjsip4net.Core.Utils;
6 | using pjsip4net.Transport;
7 |
8 | namespace pjsip4net.Interfaces
9 | {
10 | internal interface IRegistry
11 | {
12 | IContainer Container { get; set; }
13 | VoIPTransport SipTransport { get; set; }
14 | VoIPTransport RtpTransport { get; set; }
15 | UaConfig Config { get; set; }
16 | MediaConfig MediaConfig { get; set; }
17 | LoggingConfig LoggingConfig { get; set; }
18 |
19 | Tuple TransportConfig { get; set; }
20 | IEnumerable AccountConfigs { get; set; }
21 | }
22 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IVoIPTransport.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Interfaces;
4 |
5 | namespace pjsip4net.Interfaces
6 | {
7 | public interface IVoIPTransport : IIdentifiable, IInitializable
8 | {
9 | TransportType TransportType { get ; }
10 | //uint Port { get; set; }
11 | //string PublicAddress { get; set; }
12 | //string BoundAddress { get; set; }
13 | string TransportName { get; }
14 | string TransportDescription { get; }
15 | bool? IsReliable { get; }
16 | bool? IsSecure { get; }
17 | TransportConfig Config { get; }
18 |
19 | void SetConfig(TransportConfig config);
20 | void SetId(int id);
21 | }
22 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/BuddyInfo.cs:
--------------------------------------------------------------------------------
1 | namespace pjsip4net.Core.Data
2 | {
3 | public class BuddyInfo
4 | {
5 | public int Id { get; set; }
6 | public string Uri { get; set; }
7 | public string Contact { get; set; }
8 | public BuddyStatus Status { get; set; }
9 | public string StatusText { get; set; }
10 | public bool MonitorPresence { get; set; }
11 | public SubscriptionState SubState { get; set; }
12 | public string SubscriptionStateName { get; set; }
13 | public string SubTermReason { get; set; }
14 | public RpidElement Rpid { get; set; }
15 | //public pjsip_pres_status pres_status { get; set; }
16 | /// char[512]
17 | public string Buffer { get; set; }
18 | }
19 | }
--------------------------------------------------------------------------------
/uppercut/project.rb:
--------------------------------------------------------------------------------
1 | module Uppercutbuild
2 | class Project
3 |
4 | def initialize
5 | # @config_file = ".uc/options.yaml"
6 | end
7 |
8 | # def ensure_default_config
9 | # if File.exist? @config_file
10 | # return
11 | # end
12 | # add_file @config_file
13 | # content = YAML::dump( {'lib'=>'lib'} )
14 | # append_file @config_file, content
15 | # end
16 |
17 | def get_location
18 | # content = YAML.load_file @config_file
19 | # content['lib']
20 | ""
21 | end
22 |
23 | #def set_location(name)
24 | # File.delete @config_file if File.exist? @config_file
25 |
26 | # content = YAML::dump( { 'lib' => name })
27 |
28 | # File.open(@config_file, 'w') {|f| f.write(content) }
29 | # end
30 | end
31 | end
--------------------------------------------------------------------------------
/gems/__RENAME__.gemspec.rename:
--------------------------------------------------------------------------------
1 | version = File.read(File.expand_path("../VERSION",__FILE__)).strip
2 |
3 | Gem::Specification.new do |spec|
4 | spec.platform = Gem::Platform::RUBY
5 | spec.name = '__RENAME__'
6 | spec.version = version
7 | spec.files = Dir['lib/**/*'] + Dir['docs/**/*'] #+ Dir['bin/**/*']
8 | # spec.bindir = 'bin'
9 | # spec.executables << '__REPLACE__'
10 |
11 | # spec.add_dependency('log4net','= 1.2.10.0')
12 |
13 | spec.summary = '__REPLACE__'
14 | spec.description = <<-EOF
15 | __REPLACE__
16 |
17 | EOF
18 |
19 | spec.author = '__REPLACE__'
20 | # spec.authors = ['__REPLACE__','__REPLACE__']
21 | spec.email = '__REPLACE__'
22 | spec.homepage = '__REPLACE__'
23 | spec.rubyforge_project = '__RENAME__'
24 | end
--------------------------------------------------------------------------------
/pjsip4net/PagerEventArgs.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net
4 | {
5 | public class PagerEventArgs : EventArgs
6 | {
7 | public PagerEventArgs(string from, string to, string contact, string mime, int callId, string body)
8 | {
9 | From = from;
10 | To = to;
11 | Contact = contact;
12 | MimeType = mime;
13 | CallId = callId;
14 | Body = body;
15 | }
16 |
17 | public string From { get; private set; }
18 | public string To { get; private set; }
19 | public string Contact { get; private set; }
20 | public string MimeType { get; private set; }
21 | public int CallId { get; private set; }
22 | public string Body { get; private set; }
23 | }
24 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Interfaces/IInitializable.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net.Core.Interfaces
4 | {
5 | ///
6 | /// Marks class' instance as the one that demand initialization prior its' use.
7 | ///
8 | public interface IInitializable
9 | {
10 | void BeginInit();
11 | void EndInit();
12 | ///
13 | /// Signals whether an object has been initialized.
14 | ///
15 | bool IsInitialized { get; }
16 | ///
17 | /// A smart-pointer-like idiom to wrap initialization session.
18 | ///
19 | /// May very well be replaced with more usual BeginInit() EndInit() imperative method calls.
20 | IDisposable InitializationScope();
21 | }
22 | }
--------------------------------------------------------------------------------
/Tests/pjsip4net.Testing/TestConfigurator.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Interfaces;
2 | using pjsip4net.Core.Interfaces.ApiProviders;
3 |
4 | namespace pjsip4net.Testing
5 | {
6 | public class TestConfigurator : IConfigureApi
7 | {
8 | public void Configure(IContainer container)
9 | {
10 | container.RegisterAsSingleton()
11 | .RegisterAsSingleton()
12 | .RegisterAsSingleton()
13 | .RegisterAsSingleton()
14 | .RegisterAsSingleton()
15 | .RegisterAsSingleton();
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/Tests/pjsip4net.Testing/TransportApiTestProvider.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Interfaces.ApiProviders;
4 |
5 | namespace pjsip4net.Testing
6 | {
7 | public class TransportApiTestProvider : ITransportApiProvider
8 | {
9 | public TransportConfig GetDefaultConfig()
10 | {
11 | return new TransportConfig();
12 | }
13 |
14 | public int CreateTransportAndGetId(TransportType type, TransportConfig cfg)
15 | {
16 | return 0;
17 | }
18 |
19 | public TransportInfo GetTransportInfo(int id)
20 | {
21 | return new TransportInfo();
22 | }
23 |
24 | public void CloseTransport(int id)
25 | {
26 | }
27 |
28 | public void ForceCloseTransport(int id)
29 | {
30 | }
31 | }
32 | }
--------------------------------------------------------------------------------
/pjsip4net/Accounts/RegistrationSession.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Utils;
3 |
4 | namespace pjsip4net.Accounts
5 | {
6 | internal class RegistrationSession : StateMachine
7 | {
8 | private WeakReference _account;
9 |
10 | public RegistrationSession(Account owner)
11 | {
12 | Helper.GuardNotNull(owner);
13 | _account = new WeakReference(owner);
14 | _state = new InitializingAccountState(this);
15 | }
16 |
17 | public Account Account
18 | {
19 | get
20 | {
21 | if (_account.IsAlive)
22 | return (Account)_account.Target;
23 | throw new ObjectDisposedException("account");
24 | }
25 | }
26 |
27 | public virtual bool IsRegistered { get; set; }
28 | }
29 | }
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/given_a_valueWrapper.cs:
--------------------------------------------------------------------------------
1 | using NUnit.Framework;
2 | using pjsip4net.Core.Utils;
3 |
4 | namespace pjsip4net.Tests
5 | {
6 | // ReSharper disable InconsistentNaming
7 | [TestFixture]
8 | public class given_a_valueWrapper
9 | {
10 | [Test]
11 | public void when_Equals_called_with_same_value_wrapped__should_return_true()
12 | {
13 | var vw1 = new ValueWrapper(0);
14 | Assert.AreEqual(new ValueWrapper(0), vw1);
15 | }
16 |
17 | [Test]
18 | public void when_Equals_called_with_different_value_wrapped__should_return_false()
19 | {
20 | var vw1 = new ValueWrapper(0);
21 |
22 | Assert.IsFalse(vw1.Equals(new ValueWrapper(1)));
23 | }
24 |
25 | }
26 | // ReSharper restore InconsistentNaming
27 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/ISipUserAgent.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Interfaces;
3 |
4 | namespace pjsip4net.Interfaces
5 | {
6 | public interface ISipUserAgent : IDisposable
7 | {
8 | IImManager ImManager { get; }
9 | ICallManager CallManager { get; }
10 | IAccountManager AccountManager { get; }
11 | IMediaManager MediaManager { get; }
12 |
13 | event EventHandler Log;
14 |
15 | ISipUserAgent Start();
16 | void DumpInfo(bool detail);
17 | void Destroy();
18 | }
19 |
20 | internal interface ISipUserAgentInternal : ISipUserAgent
21 | {
22 | IContainer Container { get; }
23 |
24 | void SetManagers(IImManager imManager, ICallManager callManager, IAccountManager accountManager,
25 | IMediaManager mediaManager);
26 | }
27 | }
--------------------------------------------------------------------------------
/pjsip4net/Configuration/DefaultMediaComponentConfigurator.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Data;
2 | using pjsip4net.Core.Interfaces;
3 | using pjsip4net.Core.Utils;
4 | using pjsip4net.Interfaces;
5 | using pjsip4net.Media;
6 |
7 | namespace pjsip4net.Configuration
8 | {
9 | public class DefaultMediaComponentConfigurator : IConfigureComponents
10 | {
11 | public void Configure(IContainer container)
12 | {
13 | Helper.GuardNotNull(container);
14 | container.RegisterAsSingleton();
15 | container.RegisterAsSingleton();
16 | container.Register();
17 | container.Register();
18 | container.Register();
19 | }
20 | }
21 | }
--------------------------------------------------------------------------------
/uppercut/config.rb:
--------------------------------------------------------------------------------
1 | #require 'yaml'
2 | require 'thor'
3 | require 'FileUtils'
4 |
5 | module Uppercutbuild
6 | #class Config < Thor::Group
7 | #include Thor::Actions
8 |
9 | #@config_file = ".nu/options.yaml"
10 |
11 | #def self.get_config
12 | # unless File.exists? @config_file
13 | # FileUtils.touch @config_file
14 | # append_file @config_file, YAML::dump({})
15 | # end
16 | # cd = YAML.load_file @config_file
17 | # cd = ask_about_libdir cd
18 | #
19 | # save_file cd
20 | # cd
21 | #end
22 |
23 | #def self.ask_about_libdir(config)
24 | # if config['lib'].nil?
25 | # loc = ask "Where do you want me to copy things to?"
26 | # config = {'lib'=>loc}
27 | # end
28 | # config
29 | #end
30 |
31 | #def self.save_file(config)
32 | # File.open(@config_file, 'w') do |out|
33 | # YAML.dump( config, out)
34 | # end
35 | #end
36 | #end
37 | end
--------------------------------------------------------------------------------
/lib/NUnit/test.conf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Testing
6 |
7 |
8 | Testing
9 | pnunit.tests.dll
10 | TestLibraries.Testing.EqualTo19
11 | localhost:8080
12 |
13 | ..\server
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/given_a_default_transport_configurator.cs:
--------------------------------------------------------------------------------
1 | using Moq;
2 | using NUnit.Framework;
3 | using pjsip4net.Configuration;
4 | using pjsip4net.Core;
5 | using pjsip4net.Interfaces;
6 | using pjsip4net.Transport;
7 |
8 | namespace pjsip4net.Tests
9 | {
10 | // ReSharper disable InconsistentNaming
11 | [TestFixture]
12 | public class given_a_default_transport_configurator :
13 | given_a_component_configurator
14 | {
15 | [Test]
16 | public void when_configure_is_called__should_register_default_transportFactory_as_singleton()
17 | {
18 | when_configure_called();
19 | _container.Verify(x => x.RegisterAsSingleton(),
20 | Times.Exactly(1));
21 | }
22 | }
23 | // ReSharper restore InconsistentNaming
24 | }
--------------------------------------------------------------------------------
/Tests/pjsip4net.Testing/BasicApiTestProvider.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Interfaces.ApiProviders;
4 |
5 | namespace pjsip4net.Testing
6 | {
7 | public class BasicApiTestProvider : IBasicApiProvider
8 | {
9 | public UaConfig GetDefaultUaConfig()
10 | {
11 | return new UaConfig();
12 | }
13 |
14 | public LoggingConfig GetDefaultLoggingConfig()
15 | {
16 | return new LoggingConfig();
17 | }
18 |
19 | public void InitPjsua(UaConfig uaCfg, LoggingConfig logCfg, MediaConfig mediaCfg)
20 | {
21 | }
22 |
23 | public void CreatePjsua()
24 | {
25 | }
26 |
27 | public void Start()
28 | {
29 | }
30 |
31 | public void Destroy()
32 | {
33 | }
34 |
35 | public void Dump(bool detail)
36 | {
37 | }
38 | }
39 | }
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/Accounts/AccountCustomization.cs:
--------------------------------------------------------------------------------
1 | using Moq;
2 | using pjsip4net.Accounts;
3 | using pjsip4net.Core.Interfaces.ApiProviders;
4 | using pjsip4net.Transport;
5 | using Ploeh.AutoFixture;
6 | using pjsip4net.Interfaces;
7 |
8 | namespace pjsip4net.Tests.Accounts
9 | {
10 | public class AccountCustomization : ICustomization
11 | {
12 | public void Customize(IFixture fixture)
13 | {
14 | fixture.Customize(x => x.FromFactory(t => new UdpTransport(t)));
15 | fixture.Customize(x => x.OmitAutoProperties());
16 | var account = fixture.Freeze>();
17 | account.SetupGet(x => x.Id).Returns(fixture.CreateAnonymous());
18 | account.SetupGet(x => x.Transport).Returns(fixture.CreateAnonymous());
19 | fixture.Register(() => account.Object);
20 | }
21 | }
22 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Utils/StateMachine.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net.Core.Utils
4 | {
5 | public class StateMachine
6 | {
7 | protected AbstractState _state;
8 |
9 | public AbstractState CurrentState
10 | {
11 | get { return _state; }
12 | }
13 |
14 | public event EventHandler StateChanged = delegate { };
15 |
16 | protected virtual void OnStateChanged()
17 | {
18 | StateChanged(this, EventArgs.Empty);
19 | }
20 |
21 | public virtual void HandleStateChanged()
22 | {
23 | if (_state != null)
24 | _state.StateChanged();
25 | }
26 |
27 | public virtual void ChangeState(AbstractState newState)
28 | {
29 | Helper.GuardNotNull(newState);
30 | _state = newState;
31 | OnStateChanged();
32 | }
33 | }
34 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Interfaces/ApiProviders/IBasicApiProvider.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Data;
2 |
3 | namespace pjsip4net.Core.Interfaces.ApiProviders
4 | {
5 | ///
6 | /// An abstraction of service enabling access to pjsua basic API
7 | ///
8 | public interface IBasicApiProvider
9 | {
10 | UaConfig GetDefaultUaConfig();
11 | LoggingConfig GetDefaultLoggingConfig();
12 | void InitPjsua(UaConfig uaCfg, LoggingConfig logCfg, MediaConfig mediaCfg);
13 | void CreatePjsua();
14 | void Start();
15 | void Destroy();
16 | //int pjsua_handle_events(uint msec_timeout);
17 | //int pjsua_reconfigure_logging(pjsua_logging_config c);
18 | //int pjsua_detect_nat_type();
19 | //int pjsua_get_nat_type(ref pj_stun_nat_type type);
20 | void Dump(bool detail);
21 | }
22 | }
--------------------------------------------------------------------------------
/pjsip4net/Logging.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Data.Events;
3 |
4 | namespace pjsip4net
5 | {
6 | public static class Logging
7 | {
8 | public static void Log (this ILog logger, LogRequested @event)
9 | {
10 | var message = @event.Message;
11 | switch (@event.Level)
12 | {
13 | case 5:
14 | case 4:
15 | logger.Debug(message);
16 | break;
17 | case 3:
18 | logger.Info(message);
19 | break;
20 | case 2:
21 | logger.Warn(message);
22 | break;
23 | case 1:
24 | logger.Error(message);
25 | break;
26 | case 0:
27 | logger.Fatal(message);
28 | break;
29 | }
30 | }
31 | }
32 | }
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/bug_report.md:
--------------------------------------------------------------------------------
1 | ---
2 | name: Bug report
3 | about: Create a report to help us improve
4 |
5 | ---
6 |
7 | **Describe the bug**
8 | A clear and concise description of what the bug is.
9 |
10 | **To Reproduce**
11 | Steps to reproduce the behavior:
12 | 1. '...'
13 | 2. '....'
14 | 3. '....'
15 |
16 | **Expected behavior**
17 | A clear and concise description of what you expected to happen.
18 |
19 | **Screenshots**
20 | If applicable, add screenshots to help explain your problem.
21 |
22 | **Environment (please complete the following information):**
23 | - OS: [e.g. iOS]
24 | - A type of network between you and your callee/registrar server [e.g. NAT, firewall, etc]
25 | - Version [e.g. 22]
26 |
27 | **App configuration (please complete the following information):**
28 | - Either an xml config: [e.g. App.config]
29 | - or a code config: [e.g. custom IConfigurationProvider, fluent config]
30 |
31 | **Additional context**
32 | Add any other context about the problem here.
33 |
--------------------------------------------------------------------------------
/pjsip4net/Calls/DisconnectedMediaState.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Common.Logging;
3 | using pjsip4net.Core.Data;
4 | using pjsip4net.Core.Utils;
5 |
6 | namespace pjsip4net.Calls
7 | {
8 | internal class DisconnectedMediaState : AbstractState
9 | {
10 | public DisconnectedMediaState(MediaSession context)
11 | : base(context)
12 | {
13 | try
14 | {
15 | LogManager.GetLogger()
16 | .DebugFormat("Call {0} {1}", _context.Call.Id, GetType().Name);
17 | _context.IsActive = false;
18 | _context.IsHeld = false;
19 | _context.MediaState = CallMediaState.Disconnected;
20 | _context.CallManager.TerminateCall(_context.Call);
21 | }
22 | catch (ObjectDisposedException)
23 | {
24 | }
25 | }
26 |
27 | public override void StateChanged()
28 | {
29 | }
30 | }
31 | }
--------------------------------------------------------------------------------
/nuget/pjsip4net.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | pjsip4net
5 | DO_NOT_EDIT
6 | Boris Tveritnev
7 | Boris Tveritnev
8 | A high-level SIP phone API for .Net
9 | A high-level SIP phone API for .Net powered by pjsip project
10 | https://github.com/siniypin/pjsip4net
11 | http://www.apache.org/licenses/LICENSE-2.0
12 |
14 | pjsip4net pjsip sip voip
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/CallInfo.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net.Core.Data
4 | {
5 | public class CallInfo
6 | {
7 | public int Id { get; set; }
8 | public SipRole Role { get; set; }
9 | public int AccId { get; set; }
10 | public string LocalInfo { get; set; }
11 | public string LocalContact { get; set; }
12 | public string RemoteInfo { get; set; }
13 | public string RemoteContact { get; set; }
14 | public string CallId { get; set; }
15 | public InviteState State { get; set; }
16 | public string StateText { get; set; }
17 | public SipStatusCode LastStatus { get; set; }
18 | public string LastStatusText { get; set; }
19 | public virtual CallMediaState MediaStatus { get; set; }
20 | public MediaDirection MediaDir { get; set; }
21 | public int ConfSlot { get; set; }
22 | public TimeSpan ConnectDuration { get; set; }
23 | public TimeSpan TotalDuration { get; set; }
24 | }
25 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Utils/NfaState.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net.Core.Utils
4 | {
5 | public class NfaState : AbstractState
6 | {
7 | public NfaState(StateMachine owner)
8 | : base(owner)
9 | {
10 | StateType = StateType.NormalState;
11 | }
12 |
13 | public Q Id { get; set; }
14 |
15 | public StateType StateType { get; set; }
16 | public Action Act { get; set; }
17 |
18 | public virtual void NextToken(S token)
19 | {
20 | }
21 |
22 | public virtual void ClearState()
23 | {
24 | }
25 |
26 | #region Overrides of AbstractState
27 |
28 | public override void StateChanged()
29 | {
30 | //if (Act != null) Act();
31 | }
32 |
33 | #endregion
34 | }
35 |
36 | public enum StateType
37 | {
38 | StartState,
39 | FinalState,
40 | NormalState,
41 | SinkState
42 | }
43 | }
--------------------------------------------------------------------------------
/pjsip.Interop/Services/TransportInfoConverter.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using AutoMapper;
3 | using pjsip4net.Core.Data;
4 |
5 | namespace pjsip.Interop.Services
6 | {
7 | public class TransportInfoConverter : ITypeConverter
8 | {
9 | #region Implementation of ITypeConverter
10 |
11 | public TransportInfo Convert(ResolutionContext context)
12 | {
13 | var x = (pjsua_transport_info) context.SourceValue;
14 | var rx = (TransportInfo) context.DestinationValue ?? new TransportInfo();
15 | rx.AddrLen = x.addr_len;
16 | rx.Flag = x.flag;
17 | rx.Id = x.id;
18 | rx.Info = x.info;
19 | //rx.Host = x.local_name.host;
20 | //rx.Port = x.local_name.port;
21 | rx.Type = x.type.ToTransportType();
22 | rx.TypeName = x.type_name;
23 | //rx.UsageCount = x.usage_count;
24 | return rx;
25 | }
26 |
27 | #endregion
28 | }
29 | }
--------------------------------------------------------------------------------
/pjsip.Interop/Services/ConferencePortInfoConverter.cs:
--------------------------------------------------------------------------------
1 | using System.Linq;
2 | using AutoMapper;
3 | using pjsip4net.Core.Data;
4 |
5 | namespace pjsip.Interop.Services
6 | {
7 | public class ConferencePortInfoConverter : ITypeConverter
8 | {
9 | #region Implementation of ITypeConverter
10 |
11 | public ConferencePortInfo Convert(ResolutionContext context)
12 | {
13 | var x = (pjsua_conf_port_info)context.SourceValue;
14 | var rx = (ConferencePortInfo)context.DestinationValue ?? new ConferencePortInfo();
15 |
16 | rx.BitsPerSample = x.bits_per_sample;
17 | rx.ChannelCount = x.channel_count;
18 | rx.ClockRate = x.clock_rate;
19 | rx.Listeners = x.listeners.ToList();
20 | rx.Name = x.name;
21 | rx.SamplesPerFrame = x.samples_per_frame;
22 | rx.SlotId = x.slot_id;
23 |
24 | return rx;
25 | }
26 |
27 | #endregion
28 | }
29 | }
--------------------------------------------------------------------------------
/pjsip4net/Configuration/DefaultAgentConfigurator.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Interfaces;
2 | using pjsip4net.Core.Interfaces.ApiProviders;
3 | using pjsip4net.Interfaces;
4 |
5 | namespace pjsip4net.Configuration
6 | {
7 | public class DefaultAgentConfigurator : IConfigureComponents
8 | {
9 | public void Configure(IContainer container)
10 | {
11 | var basicApiProvider = container.Get();
12 | var registry = container.Get();
13 | registry.Config = basicApiProvider.GetDefaultUaConfig();
14 | registry.LoggingConfig = basicApiProvider.GetDefaultLoggingConfig();
15 | registry.MediaConfig = container.Get().GetDefaultConfig();
16 |
17 | container.RegisterAsSingleton(registry.LoggingConfig);
18 | container.RegisterAsSingleton(registry.Config);
19 | container.RegisterAsSingleton(registry.MediaConfig);
20 |
21 | container.RegisterAsSingleton();
22 | }
23 | }
24 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/ErrorMediaState.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Calls
6 | {
7 | internal class ErrorMediaState : AbstractState
8 | {
9 | public ErrorMediaState(MediaSession context)
10 | : base(context)
11 | {
12 | _context.IsHeld = false;
13 | LogManager.GetLogger()
14 | .DebugFormat("Call {0} {1}", _context.Call.Id, GetType().Name);
15 | _context.MediaState = CallMediaState.Error;
16 | //disconnect call's media from sound device if connected
17 | if (_context.IsActive)
18 | {
19 | _context.IsActive = false;
20 | _context.ConferenceBridge.DisconnectFromSoundDevice(
21 | _context.Call.ConferenceSlotId);
22 | }
23 | }
24 |
25 | #region Overrides of AbstractState
26 |
27 | public override void StateChanged()
28 | {
29 | }
30 |
31 | #endregion
32 | }
33 | }
--------------------------------------------------------------------------------
/pjsip4net/Configuration/DefaultComponentConfigurator.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core;
2 | using pjsip4net.Core.Interfaces;
3 | using pjsip4net.Core.Utils;
4 | using pjsip4net.IM;
5 | using pjsip4net.IM.Dsl;
6 | using pjsip4net.Interfaces;
7 |
8 | namespace pjsip4net.Configuration
9 | {
10 | public class DefaultComponentConfigurator : IConfigureComponents
11 | {
12 | #region Implementation of IConfigureComponents
13 |
14 | public void Configure(IContainer container)
15 | {
16 | Helper.GuardNotNull(container);
17 |
18 | container.RegisterAsSingleton();
19 | container.RegisterAsSingleton();
20 | container.RegisterAsSingleton();
21 | container.Register();
22 | container.Register();
23 | container.Register();
24 | }
25 |
26 | #endregion
27 | }
28 | }
--------------------------------------------------------------------------------
/pjsip4net/Configuration/SipUriValidator.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Configuration;
3 | using pjsip4net.Core;
4 | using pjsip4net.Core.Utils;
5 |
6 | namespace pjsip4net.Configuration
7 | {
8 | internal class SipUriValidator : ConfigurationValidatorBase
9 | {
10 | public override void Validate(object value)
11 | {
12 | try
13 | {
14 | Helper.GuardIsTrue(new SipUriParser(value.ToString()).IsValid);
15 | }
16 | catch (PjsipErrorException ex)
17 | {
18 | throw new ConfigurationErrorsException("Invalid sip uri", ex);
19 | }
20 | }
21 |
22 | public override bool CanValidate(Type type)
23 | {
24 | return type.Equals(typeof (string));
25 | }
26 | }
27 |
28 | internal class SipUriValidatorAttribute : ConfigurationValidatorAttribute
29 | {
30 | public override ConfigurationValidatorBase ValidatorInstance
31 | {
32 | get { return new SipUriValidator(); }
33 | }
34 | }
35 | }
--------------------------------------------------------------------------------
/pjsip4net.Container.Castle/ConfigureCastleContainer.cs:
--------------------------------------------------------------------------------
1 | using Castle.Windsor;
2 | using pjsip4net.Core.Configuration;
3 |
4 | namespace pjsip4net.Container.Castle
5 | {
6 | public static class ConfigureCastleContainer
7 | {
8 | public static Configure CastleContainer(this Configure config)
9 | {
10 | ConfigureContainer.Set(new CastleContainerAdapter(), config);
11 | return config;
12 | }
13 |
14 | public static Configure CastleContainer(this Configure config, IWindsorContainer windsorContainer)
15 | {
16 | ConfigureContainer.Set(new CastleContainerAdapter(windsorContainer), config);
17 | return config;
18 | }
19 |
20 | public static Configure With_CastleContainer(this Configure config)
21 | {
22 | return config.CastleContainer();
23 | }
24 |
25 | public static Configure With_CastleContainer(this Configure config, IWindsorContainer windsorContainer)
26 | {
27 | return config.CastleContainer(windsorContainer);
28 | }
29 | }
30 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/NullInviteState.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Calls
6 | {
7 | ///
8 | /// Before INVITE is sent or received
9 | ///
10 | internal class NullInviteState : AbstractState
11 | {
12 | public NullInviteState(SignallingSession context)
13 | : base(context)
14 | {
15 | LogManager.GetLogger()
16 | .DebugFormat("Call {0} {1}", _context.Call.Id, GetType().Name);
17 | _context.InviteState = InviteState.None;
18 | }
19 |
20 | #region Overrides of AbstractState
21 |
22 | public override void StateChanged()
23 | {
24 | CallInfo info = _context.Call.GetCallInfo();
25 | if (info.State == InviteState.Disconnected)
26 | _context.ChangeState(new DisconnectedInviteState(_context));
27 | else
28 | _context.ChangeState(new CallingInviteState(_context)); //after INVITE is sent
29 | }
30 |
31 | #endregion
32 | }
33 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IMediaManager.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using System.Collections.ObjectModel;
3 | using pjsip4net.Core.Data;
4 | using pjsip4net.Core.Interfaces;
5 | using pjsip4net.Core.Interfaces.ApiProviders;
6 |
7 | namespace pjsip4net.Interfaces
8 | {
9 | public interface IMediaManager
10 | {
11 | IMediaApiProvider Provider { get; }
12 |
13 | IConferenceBridge ConferenceBridge { get; }
14 | ReadOnlyCollection Codecs { get; }
15 | ReadOnlyCollection SoundDevices { get; }
16 | IEnumerable PlaybackDevices { get; }
17 | IEnumerable CaptureDevices { get; }
18 | SoundDeviceInfo CurrentPlaybackDevice { get; }
19 | SoundDeviceInfo CurrentCaptureDevice { get; }
20 | void ToggleMute();
21 | void SetSoundDevices(SoundDeviceInfo playback, SoundDeviceInfo capture);
22 | void SetSoundDevices(int playback, int capture);
23 | }
24 |
25 | internal interface IMediaManagerInternal : IMediaManager, IInitializable
26 | {
27 | void SetDevices();
28 | }
29 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Interfaces/ApiProviders/ITransportApiProvider.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Data;
2 |
3 | namespace pjsip4net.Core.Interfaces.ApiProviders
4 | {
5 | ///
6 | /// An abstraction of service enabling access to pjsua transport API
7 | ///
8 | public interface ITransportApiProvider
9 | {
10 | //void pjsua_transport_config_default(pjsua_transport_config cfg);
11 | TransportConfig GetDefaultConfig();
12 | //int pjsua_transport_create(pjsip_transport_type_e type, pjsua_transport_config cfg, ref int p_id);
13 | int CreateTransportAndGetId(TransportType type, TransportConfig cfg);
14 | //int pjsua_enum_transports(int[] id, ref uint count);
15 | TransportInfo GetTransportInfo(int id);
16 | //int pjsua_transport_get_info(int id, pjsua_transport_info info);
17 | //int pjsua_transport_set_enable(int id, int enabled);
18 | //int pjsua_transport_close(int id, int force);
19 | void CloseTransport(int id);
20 | void ForceCloseTransport(int id);
21 | }
22 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/ConnectingInviteState.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Calls
6 | {
7 | ///
8 | /// After 2xx is sent/received
9 | ///
10 | internal class ConnectingInviteState : AbstractState
11 | {
12 | public ConnectingInviteState(SignallingSession context)
13 | : base(context)
14 | {
15 | LogManager.GetLogger()
16 | .DebugFormat("Call {0} {1}", _context.Call.Id, GetType().Name);
17 | _context.InviteState = InviteState.Connecting;
18 | }
19 |
20 | #region Overrides of AbstractState
21 |
22 | public override void StateChanged()
23 | {
24 | CallInfo info = _context.Call.GetCallInfo();
25 | if (info.State == InviteState.Confirmed)
26 | _context.ChangeState(new ConfirmedInviteState(_context));
27 | else if (info.State == InviteState.Disconnected)
28 | _context.ChangeState(new DisconnectedInviteState(_context));
29 | }
30 |
31 | #endregion
32 | }
33 | }
--------------------------------------------------------------------------------
/pjsip4net/Configuration/ProxyElement.cs:
--------------------------------------------------------------------------------
1 | using System.Configuration;
2 |
3 | namespace pjsip4net.Configuration
4 | {
5 | public class ProxyElement : ConfigurationElement
6 | {
7 | private static ConfigurationProperty _addressProp;
8 | private readonly ConfigurationPropertyCollection _properties;
9 |
10 | public ProxyElement()
11 | {
12 | _addressProp = new ConfigurationProperty("address", typeof (string), "",
13 | ConfigurationPropertyOptions.IsRequired);
14 | _properties = new ConfigurationPropertyCollection
15 | {
16 | _addressProp
17 | };
18 | }
19 |
20 | [ConfigurationProperty("address", DefaultValue = "", IsRequired = true)]
21 | public string Address
22 | {
23 | get { return base[_addressProp].ToString(); }
24 | set { base[_addressProp] = value; }
25 | }
26 |
27 | protected override ConfigurationPropertyCollection Properties
28 | {
29 | get { return _properties; }
30 | }
31 | }
32 | }
--------------------------------------------------------------------------------
/test.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 |
3 | ::Project UppercuT - http://uppercut.googlecode.com
4 | ::No edits to this file are required - http://uppercut.pbwiki.com
5 |
6 | if '%2' NEQ '' goto usage
7 | if '%3' NEQ '' goto usage
8 | if '%1' == '/?' goto usage
9 | if '%1' == '-?' goto usage
10 | if '%1' == '?' goto usage
11 | if '%1' == '/help' goto usage
12 |
13 | SET DIR=%cd%
14 | SET BUILD_DIR=%~d0%~p0%
15 | SET NANT="%BUILD_DIR%lib\Nant\nant.exe"
16 | SET build.config.settings="%DIR%\settings\UppercuT.config"
17 |
18 | %NANT% /f:%BUILD_DIR%build\compile.step -D:build.config.settings=%build.config.settings%
19 |
20 | if %ERRORLEVEL% NEQ 0 goto errors
21 |
22 | %NANT% -logger:NAnt.Core.DefaultLogger -quiet /f:%BUILD_DIR%build\analyzers\test.step %1 -D:build.config.settings=%build.config.settings%
23 | %NANT% -logger:NAnt.Core.DefaultLogger -quiet /f:%BUILD_DIR%build\analyzers\test.step open_results -D:build.config.settings=%build.config.settings%
24 |
25 | if %ERRORLEVEL% NEQ 0 goto errors
26 |
27 | goto finish
28 |
29 | :usage
30 | echo.
31 | echo Usage: test.bat
32 | echo Usage: test.bat all - to run all tests
33 | echo.
34 | goto finish
35 |
36 | :errors
37 | EXIT /B %ERRORLEVEL%
38 |
39 | :finish
--------------------------------------------------------------------------------
/pjsip4net/Configuration/DnsServerElement.cs:
--------------------------------------------------------------------------------
1 | using System.Configuration;
2 |
3 | namespace pjsip4net.Configuration
4 | {
5 | public class DnsServerElement : ConfigurationElement
6 | {
7 | private static ConfigurationProperty _addressProp;
8 | private readonly ConfigurationPropertyCollection _properties;
9 |
10 | public DnsServerElement()
11 | {
12 | _addressProp = new ConfigurationProperty("address", typeof (string), "",
13 | ConfigurationPropertyOptions.IsRequired);
14 | _properties = new ConfigurationPropertyCollection
15 | {
16 | _addressProp
17 | };
18 | }
19 |
20 | [ConfigurationProperty("address", DefaultValue = "", IsRequired = true)]
21 | public string Address
22 | {
23 | get { return base[_addressProp].ToString(); }
24 | set { base[_addressProp] = value; }
25 | }
26 |
27 | protected override ConfigurationPropertyCollection Properties
28 | {
29 | get { return _properties; }
30 | }
31 | }
32 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/ConferenceMediaStateDecorator.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Utils;
3 |
4 | namespace pjsip4net.Calls
5 | {
6 | internal class ConferenceMediaStateDecorator : AbstractState
7 | {
8 | private readonly ActiveMediaState _inner;
9 |
10 | public ConferenceMediaStateDecorator(MediaSession context, ActiveMediaState inner)
11 | : base(context)
12 | {
13 | Helper.GuardNotNull(inner);
14 | _inner = inner;
15 | LogManager.GetLogger()
16 | .DebugFormat("Call {0} {1}", _context.Call.Id, GetType().Name);
17 | _context.ConferenceBridge.ConnectCall(_context.Call);
18 | _context.IsInConference = true;
19 | }
20 |
21 | #region Overrides of AbstractState
22 |
23 | public override void StateChanged()
24 | {
25 | if (_context.IsInConference)
26 | {
27 | _context.ConferenceBridge.DisconnectCall(_context.Call);
28 | _context.IsInConference = false;
29 | }
30 | _inner.StateChanged(); //let pj take care about disconnection
31 | }
32 |
33 | #endregion
34 | }
35 | }
--------------------------------------------------------------------------------
/nuget/build/pjsip4net.targets:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | .
9 |
10 |
11 |
12 |
13 | $(PrepareForRunDependsOn);
14 | CopyNativeBinaries
15 |
16 |
17 |
18 |
21 |
22 |
23 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/pjsip4net.Core/EventsProvider.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Magnum.Pipeline;
3 | using Magnum.Pipeline.Segments;
4 | using pjsip4net.Core.Interfaces;
5 |
6 | namespace pjsip4net.Core
7 | {
8 | public class EventsProvider : IEventsProvider
9 | {
10 | private readonly Pipe _eventsPipe;
11 | private readonly ISubscriptionScope _scope;
12 |
13 | public EventsProvider()
14 | {
15 | _eventsPipe = PipeSegment.Input(PipeSegment.End());;
16 | _scope = _eventsPipe.NewSubscriptionScope();
17 | }
18 |
19 | #region Implementation of IEventsProvider
20 |
21 | public void Publish(T @event) where T : class
22 | {
23 | _eventsPipe.Send(@event);
24 | }
25 |
26 | public void Subscribe(Action actOnEvent) where T : class
27 | {
28 | _scope.Subscribe(new DelegatingConsumer(actOnEvent));
29 | }
30 |
31 | public IDisposable SubscribeTemporarilly(Action actOnEvent) where T : class
32 | {
33 | var result = _eventsPipe.NewSubscriptionScope();
34 | result.Subscribe(new DelegatingConsumer(actOnEvent));
35 | return result;
36 | }
37 |
38 | #endregion
39 | }
40 | }
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/given_a_default_call_configurator.cs:
--------------------------------------------------------------------------------
1 | using Moq;
2 | using NUnit.Framework;
3 | using pjsip4net.Calls;
4 | using pjsip4net.Calls.Dsl;
5 | using pjsip4net.Configuration;
6 | using pjsip4net.Interfaces;
7 |
8 | namespace pjsip4net.Tests
9 | {
10 | // ReSharper disable InconsistentNaming
11 | [TestFixture]
12 | public class given_a_default_call_configurator : given_a_component_configurator
13 | {
14 | [Test]
15 | public void when_configure_is_called__should_register_default_call_manager_as_singleton_with_internal_interface()
16 | {
17 | _container.Setup(x => x.RegisterAsSingleton());
18 | when_configure_called();
19 | _container.Verify(x => x.RegisterAsSingleton());
20 | }
21 |
22 | [Test]
23 | public void when_configure_is_called__should_register_call_builder_as_transient()
24 | {
25 | when_configure_called();
26 | _container.Verify(x => x.Register());
27 | }
28 | }
29 | // ReSharper restore InconsistentNaming
30 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IAccountManager.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.ObjectModel;
3 | using pjsip4net.Accounts;
4 | using pjsip4net.Core.Data.Events;
5 | using pjsip4net.Core.Interfaces;
6 | using pjsip4net.Core.Interfaces.ApiProviders;
7 |
8 | namespace pjsip4net.Interfaces
9 | {
10 | ///
11 | /// Provides access to accounts registered with user agent.
12 | ///
13 | public interface IAccountManager
14 | {
15 | ReadOnlyCollection Accounts { get; }
16 | IAccount DefaultAccount { get; set; }
17 | event EventHandler AccountStateChanged;
18 |
19 | IAccount Register(Func builder);
20 | IAccount GetAccountById(int id);
21 | }
22 |
23 | internal interface IAccountManagerInternal : IAccountManager, IInitializable
24 | {
25 | IAccountApiProvider Provider { get; }
26 |
27 | void RegisterAccount(Account account, bool @default);
28 | void UnregisterAccount(Account account);
29 | void RaiseStateChanged(Account account);
30 | void OnRegistrationState(RegistrationStateChanged e);
31 | void UnRegisterAllAccounts();
32 | Account GetAccount(int id);
33 | }
34 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/EarlyInviteState.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Calls
6 | {
7 | ///
8 | /// After response with To tag
9 | ///
10 | internal class EarlyInviteState : AbstractState
11 | {
12 | public EarlyInviteState(SignallingSession context)
13 | : base(context)
14 | {
15 | LogManager.GetLogger()
16 | .DebugFormat("Call {0} {1}", _context.Call.Id, GetType().Name);
17 | _context.InviteState = InviteState.Early;
18 | }
19 |
20 | #region Overrides of AbstractState
21 |
22 | public override void StateChanged()
23 | {
24 | CallInfo info = _context.Call.GetCallInfo();
25 | if (info.State == InviteState.Confirmed)
26 | _context.ChangeState(new ConfirmedInviteState(_context));
27 | else if (info.State == InviteState.Connecting)
28 | _context.ChangeState(new ConnectingInviteState(_context));
29 | else if (info.State == InviteState.Disconnected)
30 | _context.ChangeState(new DisconnectedInviteState(_context));
31 | }
32 |
33 | #endregion
34 | }
35 | }
--------------------------------------------------------------------------------
/pjsip4net/Accounts/InitializingAccountState.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Accounts
6 | {
7 | ///
8 | /// Initial state
9 | ///
10 | internal class InitializingAccountState : AbstractState
11 | {
12 | public InitializingAccountState(RegistrationSession context)
13 | : base(context)
14 | {
15 | LogManager.GetLogger()
16 | .DebugFormat("Account {0} InitializingAccountState", _context.Account.Id);
17 | _context.IsRegistered = false;
18 | }
19 |
20 | #region Overrides of AccountState
21 |
22 | public override void StateChanged()
23 | {
24 | AccountInfo info = _context.Account.GetAccountInfo();
25 | if (_context.Account.IsLocal)
26 | _context.ChangeState(new RegisteredAccountState(_context));
27 | else if (info.Status == SipStatusCode.Trying)
28 | _context.ChangeState(new RegisteringAccountState(_context));
29 | else
30 | _context.ChangeState(new UnknownStatusState(_context, info.Status, info.StatusText));
31 | }
32 |
33 | #endregion
34 | }
35 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Resource.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Runtime.ConstrainedExecution;
3 | using pjsip4net.Core.Interfaces;
4 |
5 | namespace pjsip4net.Core
6 | {
7 | public class Resource : CriticalFinalizerObject, IResource
8 | {
9 | protected bool _isDisposed;
10 |
11 | internal bool IsDisposed
12 | {
13 | get { return _isDisposed; }
14 | }
15 |
16 | protected void GuardDisposed()
17 | {
18 | if (_isDisposed)
19 | throw new ObjectDisposedException("Initializable");
20 | }
21 |
22 | #region Implementation of IDisposable
23 |
24 | public void InternalDispose()
25 | {
26 | Dispose(true);
27 | }
28 |
29 | protected void Dispose(bool disposing)
30 | {
31 | if (_isDisposed) return;
32 |
33 | if (disposing)
34 | {
35 | _isDisposed = true;
36 | GC.SuppressFinalize(this);
37 | }
38 |
39 | CleanUp();
40 | }
41 |
42 | ~Resource()
43 | {
44 | Dispose(false);
45 | }
46 |
47 | protected virtual void CleanUp()
48 | {
49 | }
50 |
51 | #endregion
52 | }
53 | }
--------------------------------------------------------------------------------
/uppercut/cli.rb:
--------------------------------------------------------------------------------
1 | require 'FileUtils'
2 | require 'thor'
3 |
4 | module Uppercutbuild
5 | class CLI < Thor
6 | include Thor::Actions
7 |
8 | def initialize(*)
9 | super
10 |
11 | @proj = Uppercutbuild::Project.new
12 | end
13 |
14 | desc "initialize", "initializes uppercut build in the current directory"
15 | method_options :location => :string
16 | def init(*names)
17 | #@proj.ensure_default_config
18 |
19 | loc = @proj.get_location
20 | cl = options['location']
21 | loc = cl unless cl.nil?
22 |
23 | Uppercutbuild::Loader.load
24 | puts "UppercuT has been added to this project. Please look through the lib directory for items you don't need. NAnt is still required at the current time."
25 | end
26 |
27 | desc "upgrade", "upgrades the uppercut 'build' directory"
28 | method_options :location => :string
29 | def upgrade(*names)
30 | #@proj.ensure_default_config
31 |
32 | loc = @proj.get_location
33 | cl = options['location']
34 | loc = cl unless cl.nil?
35 |
36 | Uppercutbuild::Loader.upgrade
37 | puts "The build folder has been updated. Please check the release logs for items outside of this folder that may need to be updated."
38 | end
39 |
40 | def self.source_root
41 | File.dirname(__FILE__)
42 | end
43 |
44 | end
45 | end
--------------------------------------------------------------------------------
/pjsip4net.Core/Utils/SingletonHolder.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace pjsip4net.Core.Utils
4 | {
5 | //public static class SingletonHolder
6 | // where TSingleton : class
7 | //{
8 | // private static readonly object _lock = new object();
9 | // private static TSingleton _instance;
10 |
11 | // private static Func InstanceInjector;
12 |
13 | // public static TSingleton Instance
14 | // {
15 | // get
16 | // {
17 | // if (_instance == null)
18 | // lock (_lock)
19 | // if (_instance == null)
20 | // {
21 | // Helper.GuardNotNull(InstanceInjector);
22 | // _instance = InstanceInjector();
23 | // }
24 | // return _instance;
25 | // }
26 | // }
27 |
28 | // public static void SetInstanceInjector(Func injector)
29 | // {
30 | // Helper.GuardNotNull(injector);
31 | // lock (_lock)
32 | // {
33 | // if (InstanceInjector != null)
34 | // _instance = null;
35 | // InstanceInjector = injector;
36 | // }
37 | // }
38 | //}
39 | }
--------------------------------------------------------------------------------
/pjsip4net/Accounts/RegisteringAccountState.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Accounts
6 | {
7 | ///
8 | /// After remote registration session started
9 | ///
10 | internal class RegisteringAccountState : AbstractState
11 | {
12 | public RegisteringAccountState(RegistrationSession context)
13 | : base(context)
14 | {
15 | LogManager.GetLogger()
16 | .DebugFormat("Account {0} RegisteringAccountState", _context.Account.Id);
17 | _context.IsRegistered = false;
18 | }
19 |
20 | #region Overrides of AccountState
21 |
22 | public override void StateChanged()
23 | {
24 | AccountInfo info = _context.Account.GetAccountInfo();
25 | if (info.Status == SipStatusCode.RequestTimeout)
26 | _context.ChangeState(new TimedOutAccountRegistrationState(_context));
27 | else if (info.Status == SipStatusCode.Ok)
28 | _context.ChangeState(new RegisteredAccountState(_context));
29 | else
30 | _context.ChangeState(new UnknownStatusState(_context, info.Status, info.StatusText));
31 | }
32 |
33 | #endregion
34 | }
35 | }
--------------------------------------------------------------------------------
/Tests/pjsip4net.Testing/ImApiTestProvider.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Data;
2 | using pjsip4net.Core.Interfaces.ApiProviders;
3 |
4 | namespace pjsip4net.Testing
5 | {
6 | public class ImApiTestProvider : IIMApiProvider
7 | {
8 | public BuddyConfig GetDefaultConfig()
9 | {
10 | return new BuddyConfig();
11 | }
12 |
13 | public BuddyInfo GetInfo(int buddyId)
14 | {
15 | return new BuddyInfo();
16 | }
17 |
18 | public int AddBuddyAndGetId(BuddyConfig buddyCfg)
19 | {
20 | return 0;
21 | }
22 |
23 | public void DeleteBuddy(int buddyId)
24 | {
25 | }
26 |
27 | public void SubscribeBuddyPresence(int buddyId)
28 | {
29 | }
30 |
31 | public void UnsubscribeBuddyPresence(int buddyId)
32 | {
33 | }
34 |
35 | public void UpdatePresence(int buddyId)
36 | {
37 | }
38 |
39 | public void DumpPresence(bool verbose)
40 | {
41 | }
42 |
43 | public void SendIm(int accId, string to, string mimeType, string content)
44 | {
45 | }
46 |
47 | public void SendIsTyping(int accId, string to)
48 | {
49 | }
50 |
51 | public void SendIsNotTyping(int accId, string to)
52 | {
53 | }
54 | }
55 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/MediaConfig.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Net;
3 |
4 | namespace pjsip4net.Core.Data
5 | {
6 | public class MediaConfig : Initializable
7 | {
8 | public int CaptureDeviceId = -1,
9 | PlaybackDeviceId = -1;
10 |
11 | #region Properties
12 |
13 | public uint ClockRate { get; set; }
14 | public uint SndClockRate { get; set; }
15 | public uint ChannelCount { get; set; }
16 | public uint AudioFramePtime { get; set; }
17 | public uint MaxMediaPorts { get; set; }
18 | public bool HasIOQueue { get; set; }
19 | public uint ThreadCnt { get; set; }
20 | public uint Quality { get; set; }
21 | public bool IsVadEnabled { get; set; }
22 | public uint ILBCMode { get; set; }
23 | public uint EcOptions { get; set; }
24 | public uint EcTailLen { get; set; }
25 | public bool EnableICE { get; set; }
26 | public bool ICENoRtcp { get; set; }
27 | public bool EnableTurn { get; set; }
28 | public string TurnServer { get; set; }
29 | public TransportType TurnConnectionType { get; set; }
30 | public NetworkCredential TurnAuthentication { get; set; }
31 | public TimeSpan SoundDeviceAutoCloseTime { get; set; }
32 |
33 | #endregion
34 | }
35 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/NoneMediaState.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Calls
6 | {
7 | internal class NoneMediaState : AbstractState
8 | {
9 | public NoneMediaState(MediaSession context)
10 | : base(context)
11 | {
12 | LogManager.GetLogger()
13 | .DebugFormat("Call {0} {1}", _context.Call.Id, GetType().Name);
14 | _context.IsActive = false;
15 | _context.IsHeld = false;
16 | _context.MediaState = CallMediaState.None;
17 | }
18 |
19 | #region Overrides of AbstractState
20 |
21 | public override void StateChanged()
22 | {
23 | var info = _context.Call.GetCallInfo();
24 | if (info.MediaStatus == CallMediaState.Active)
25 | {
26 | if (_context.Registry.Config.AutoConference)
27 | _context.ChangeState(new ConferenceMediaStateDecorator(_context, new ActiveMediaState(_context)));
28 | else _context.ChangeState(new ActiveMediaState(_context));
29 | }
30 | else if (info.MediaStatus == CallMediaState.Error)
31 | _context.ChangeState(new ErrorMediaState(_context));
32 | }
33 |
34 | #endregion
35 | }
36 | }
--------------------------------------------------------------------------------
/pjsip.Interop/Services/AccountInfoConverter.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using AutoMapper;
3 | using pjsip4net.Core.Data;
4 |
5 | namespace pjsip.Interop.Services
6 | {
7 | public class AccountInfoConverter : ITypeConverter
8 | {
9 | #region Implementation of ITypeConverter
10 |
11 | public AccountInfo Convert(ResolutionContext context)
12 | {
13 | var x = (pjsua_acc_info) context.SourceValue;
14 | var rx = (AccountInfo) context.DestinationValue ?? new AccountInfo();
15 |
16 | rx.AccUri = x.acc_uri;
17 | rx.Expires = x.expires;
18 | rx.HasRegistration = x.has_registration;
19 | rx.Id = x.id;
20 | rx.IsDefault = x.is_default;
21 | rx.OnlineStatus = x.online_status;
22 | rx.OnlineStatusText = x.online_status_text;
23 | rx.Rpid = new RpidElement()
24 | {
25 | Activity = (RpidActivity) x.rpid.activity,
26 | Id = x.rpid.id,
27 | Note = x.rpid.note
28 | };
29 | rx.Status = (SipStatusCode) x.status;
30 | rx.StatusText = x.status_text;
31 | return rx;
32 | }
33 |
34 | #endregion
35 | }
36 | }
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IImManager.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.ObjectModel;
3 | using pjsip4net.Core.Interfaces;
4 | using pjsip4net.Core.Interfaces.ApiProviders;
5 | using pjsip4net.IM;
6 |
7 | namespace pjsip4net.Interfaces
8 | {
9 | public interface IImManager : IDisposable, IInitializable
10 | {
11 | ReadOnlyCollection Buddies { get; }
12 | event EventHandler BuddyStateChanged;
13 | event EventHandler IncomingMessage;
14 | event EventHandler TypingAlert;
15 | event EventHandler NatDetected;
16 |
17 | IBuddy RegisterBuddy(Func builder);
18 | IBuddy GetBuddyById(int id);
19 | void SendMessage(IAccount account, string body, string to);
20 | void SendMessageInDialog(ICall dialog, string body);
21 | void SendMessage(Action builder);
22 | void SendTyping(IAccount account, string to, bool isTyping);
23 | void SendTypingInDialog(ICall dialog, bool isTyping);
24 | void DumpSubscription(bool verbose);
25 | }
26 |
27 | internal interface IImManagerInternal : IImManager
28 | {
29 | IIMApiProvider Provider { get; }
30 |
31 | void RegisterBuddy(Buddy buddy);
32 | void UnregisterBuddy(Buddy buddy);
33 | }
34 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/SignallingSession.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 | using pjsip4net.Interfaces;
5 |
6 | namespace pjsip4net.Calls
7 | {
8 | internal class SignallingSession : StateMachine
9 | {
10 | private readonly ICallManagerInternal _callManager;
11 | private readonly WeakReference _call;
12 |
13 | public SignallingSession(Call owner, ICallManagerInternal callManager)
14 | {
15 | _callManager = callManager;
16 | Helper.GuardNotNull(owner);
17 | Helper.GuardNotNull(callManager);
18 | _call = new WeakReference(owner);
19 | _state = owner.IsIncoming ? (AbstractState) new IncomingInviteState(this) : new NullInviteState(this);
20 | }
21 |
22 | public Call Call
23 | {
24 | get
25 | {
26 | if (_call.IsAlive)
27 | return (Call) _call.Target;
28 | throw new ObjectDisposedException("call");
29 | }
30 | }
31 |
32 | public bool IsConfirmed { get; set; }
33 | public bool IsDisconnected { get; set; }
34 | public bool IsRinging { get; set; }
35 | public InviteState InviteState { get; set; }
36 | public ICallManagerInternal CallManager
37 | {
38 | get { return _callManager; }
39 | }
40 | }
41 | }
--------------------------------------------------------------------------------
/settings/LOCAL.settings:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/given_a_default_account_component_configurator.cs:
--------------------------------------------------------------------------------
1 | using Moq;
2 | using NUnit.Framework;
3 | using pjsip4net.Accounts;
4 | using pjsip4net.Accounts.Dsl;
5 | using pjsip4net.Configuration;
6 | using pjsip4net.Interfaces;
7 |
8 | namespace pjsip4net.Tests
9 | {
10 | // ReSharper disable InconsistentNaming
11 | [TestFixture]
12 | public class given_a_default_account_component_configurator :
13 | given_a_component_configurator
14 | {
15 | [Test]
16 | public void when_configure_is_called__should_register_default_account_manager_as_singleton_with_internal_interface()
17 | {
18 | _container.Setup(x => x.RegisterAsSingleton());
19 | when_configure_called();
20 | _container.Verify(
21 | x => x.RegisterAsSingleton(), Times.Exactly(1));
22 | }
23 |
24 | [Test]
25 | public void when_configure_is_called__should_register_account_builder_as_transient()
26 | {
27 | when_configure_called();
28 | _container.Verify(
29 | x => x.Register(), Times.Exactly(1));
30 | }
31 | }
32 | // ReSharper restore InconsistentNaming
33 | }
--------------------------------------------------------------------------------
/pjsip4net/DefaultRegistry.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using pjsip4net.Core;
3 | using pjsip4net.Core.Data;
4 | using pjsip4net.Core.Interfaces;
5 | using pjsip4net.Core.Utils;
6 | using pjsip4net.Interfaces;
7 | using pjsip4net.Transport;
8 |
9 | namespace pjsip4net
10 | {
11 | internal class DefaultRegistry : IRegistry, IConfigurationContext
12 | {
13 | #region Implementation of ILocalRegistry
14 |
15 | public IContainer Container { get; set; }
16 |
17 | public VoIPTransport SipTransport { get; set; }
18 | public VoIPTransport RtpTransport { get; set; }
19 |
20 | public UaConfig Config { get; set; }
21 | public MediaConfig MediaConfig { get; set; }
22 | public LoggingConfig LoggingConfig { get; set; }
23 | public Core.Utils.Tuple TransportConfig { get; set; }
24 | public IEnumerable AccountConfigs { get; set; }
25 |
26 | #endregion
27 |
28 | public void RegisterTransport(Core.Utils.Tuple sipTransportConfig)
29 | {
30 | Helper.GuardNotNull(sipTransportConfig);
31 | TransportConfig = sipTransportConfig;
32 | }
33 |
34 | public void RegisterAccounts(IEnumerable accountConfigs)
35 | {
36 | Helper.GuardNotNull(accountConfigs);
37 | AccountConfigs = accountConfigs;
38 | }
39 | }
40 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/CallingInviteState.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Calls
6 | {
7 | ///
8 | /// After INVITE is sent
9 | ///
10 | internal class CallingInviteState : AbstractState
11 | {
12 | public CallingInviteState(SignallingSession context)
13 | : base(context)
14 | {
15 | LogManager.GetLogger()
16 | .DebugFormat("Call {0} {1}", _context.Call.Id, GetType().Name);
17 | if (!_context.Call.IsIncoming)
18 | _context.CallManager.RaiseRingEvent(_context.Call, true);
19 | _context.IsRinging = true;
20 | _context.InviteState = InviteState.Calling;
21 | }
22 |
23 | #region Overrides of AbstractState
24 |
25 | public override void StateChanged()
26 | {
27 | CallInfo info = _context.Call.GetCallInfo();
28 | if (info.State == InviteState.Confirmed)
29 | _context.ChangeState(new ConfirmedInviteState(_context));
30 | else if (info.State == InviteState.Connecting)
31 | _context.ChangeState(new ConnectingInviteState(_context));
32 | else if (info.State == InviteState.Disconnected)
33 | _context.ChangeState(new DisconnectedInviteState(_context));
34 | }
35 |
36 | #endregion
37 | }
38 | }
--------------------------------------------------------------------------------
/pjsip.Interop/Interfaces/IMapper.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Data;
2 |
3 | namespace pjsip.Interop.Interfaces
4 | {
5 | public interface IMapper
6 | {
7 | pjsua_config Map(UaConfig config, pjsua_config cfg);
8 | UaConfig Map(pjsua_config cfg, UaConfig config);
9 | pjsua_logging_config Map(LoggingConfig config, pjsua_logging_config cfg);
10 | LoggingConfig Map(pjsua_logging_config cfg, LoggingConfig config);
11 | pjsua_media_config Map(MediaConfig config, pjsua_media_config cfg);
12 | MediaConfig Map(pjsua_media_config cfg, MediaConfig config);
13 | pjsua_transport_config Map(TransportConfig config, pjsua_transport_config cfg);
14 | TransportConfig Map(pjsua_transport_config cfg, TransportConfig config);
15 | pjsua_acc_config Map(AccountConfig config, pjsua_acc_config cfg);
16 | AccountConfig Map(pjsua_acc_config cfg, AccountConfig config);
17 | pjsua_buddy_config Map(BuddyConfig config, pjsua_buddy_config cfg);
18 | BuddyConfig Map(pjsua_buddy_config cfg, BuddyConfig config);
19 |
20 | TransportInfo Map(pjsua_transport_info info);
21 | AccountInfo Map(pjsua_acc_info info);
22 | CallInfo Map(pjsua_call_info info);
23 | ConferencePortInfo Map(pjsua_conf_port_info info);
24 | SoundDeviceInfo Map(pjmedia_snd_dev_info info);
25 | CodecInfo Map(pjsua_codec_info info);
26 | BuddyInfo Map(pjsua_buddy_info info);
27 | }
28 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/DisconnectedInviteState.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Diagnostics;
3 | using Common.Logging;
4 | using pjsip4net.Core.Data;
5 | using pjsip4net.Core.Utils;
6 | using pjsip4net.Interfaces;
7 |
8 | namespace pjsip4net.Calls
9 | {
10 | ///
11 | /// Session is terminated
12 | ///
13 | internal class DisconnectedInviteState : AbstractState
14 | {
15 | public DisconnectedInviteState(SignallingSession context)
16 | : base(context)
17 | {
18 | try
19 | {
20 | LogManager.GetLogger()
21 | .DebugFormat("Call {0} {1}", _context.Call.Id, GetType().Name);
22 |
23 | _context.IsConfirmed = false;
24 | _context.IsDisconnected = true;
25 | _context.InviteState = InviteState.Disconnected;
26 | if (_context.IsRinging)
27 | {
28 | _context.CallManager.RaiseRingEvent(_context.Call, false);
29 | _context.IsRinging = false;
30 | }
31 | _context.CallManager.TerminateCall(_context.Call);
32 | }
33 | catch (ObjectDisposedException)
34 | {
35 | }
36 | }
37 |
38 | #region Overrides of AbstractState
39 |
40 | public override void StateChanged()
41 | {
42 | }
43 |
44 | #endregion
45 | }
46 | }
--------------------------------------------------------------------------------
/pjsip4net/Accounts/TimedOutAccountRegistrationState.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Accounts
6 | {
7 | ///
8 | /// After PjsipScRequestTimeout = 408 recieved
9 | ///
10 | internal class TimedOutAccountRegistrationState : AbstractState
11 | {
12 | public TimedOutAccountRegistrationState(RegistrationSession context)
13 | : base(context)
14 | {
15 | LogManager.GetLogger()
16 | .DebugFormat("Account {0} TimedOutAccountRegistrationState", _context.Account.Id);
17 | _context.IsRegistered = false;
18 | //_owner.Account.Dispose();//account can be re-registered - no need to dispose and delete
19 | }
20 |
21 | #region Overrides of AccountState
22 |
23 | public override void StateChanged()
24 | {
25 | AccountInfo info = _context.Account.GetAccountInfo();
26 | if (info.Status == SipStatusCode.Ok)
27 | _context.ChangeState(new RegisteredAccountState(_context));
28 | else if (info.Status == SipStatusCode.Trying)
29 | _context.ChangeState(new RegisteringAccountState(_context));
30 | else
31 | _context.ChangeState(new UnknownStatusState(_context, info.Status, info.StatusText));
32 | }
33 |
34 | #endregion
35 | }
36 | }
--------------------------------------------------------------------------------
/pjsip4net/Configuration/StunElement.cs:
--------------------------------------------------------------------------------
1 | using System.Configuration;
2 |
3 | namespace pjsip4net.Configuration
4 | {
5 | public class StunElement : ConfigurationElement
6 | {
7 | //private ConfigurationProperty _domainProp = new ConfigurationProperty("domain", typeof(string), "");
8 | private readonly ConfigurationProperty _hostProp = new ConfigurationProperty("address", typeof (string), "");
9 | private readonly ConfigurationPropertyCollection _properties;
10 |
11 | //[ConfigurationProperty("domain", DefaultValue = "", IsRequired = false)]
12 | //public string Domain
13 | //{
14 | // get { return base[_domainProp].ToString(); }
15 | // set { base[_domainProp] = value; }
16 | //}
17 |
18 | public StunElement()
19 | {
20 | _properties = new ConfigurationPropertyCollection
21 | {
22 | //_domainProp,
23 | _hostProp
24 | };
25 | }
26 |
27 | [ConfigurationProperty("address", DefaultValue = "", IsRequired = true)]
28 | public string Address
29 | {
30 | get { return base[_hostProp].ToString(); }
31 | set { base[_hostProp] = value; }
32 | }
33 |
34 | protected override ConfigurationPropertyCollection Properties
35 | {
36 | get { return _properties; }
37 | }
38 | }
39 | }
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/given_a_component_configurator.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Moq;
3 | using NUnit.Framework;
4 | using pjsip4net.Core.Interfaces;
5 | using Ploeh.AutoFixture;
6 | using Ploeh.AutoFixture.AutoMoq;
7 |
8 | namespace pjsip4net.Tests
9 | {
10 | // ReSharper disable InconsistentNaming
11 | [TestFixture]
12 | public abstract class given_a_component_configurator where T : IConfigureComponents
13 | {
14 | protected IConfigureComponents _sut;
15 | protected Mock _container;
16 | protected IFixture _fixture;
17 |
18 | [SetUp]
19 | public void TestSetup()
20 | {
21 | _fixture = new Fixture().Customize(new AutoMoqCustomization());
22 | _container = _fixture.Freeze>();
23 | _sut = _fixture.CreateAnonymous();
24 | }
25 |
26 | [TearDown]
27 | public void Teardown()
28 | {
29 | _sut = null;
30 | _container = null;
31 | }
32 |
33 | [Test, ExpectedException(typeof(ArgumentNullException))]
34 | public void when_configure_is_called_with_null_container_should_throw_exception()
35 | {
36 | _sut.Configure(null);
37 | Assert.Fail("Should have thrown an exception");
38 | }
39 |
40 | protected void when_configure_called()
41 | {
42 | _sut.Configure(_container.Object);
43 | }
44 | }
45 | // ReSharper restore InconsistentNaming
46 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/IncomingInviteState.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Calls
6 | {
7 | ///
8 | /// After INVITE is received
9 | ///
10 | internal class IncomingInviteState : AbstractState
11 | {
12 | public IncomingInviteState(SignallingSession context)
13 | : base(context)
14 | {
15 | LogManager.GetLogger()
16 | .DebugFormat("Call {0} {1}", _context.Call.Id, GetType().Name);
17 | _context.CallManager.RaiseRingEvent(_context.Call, false);
18 | _context.IsRinging = true;
19 | _context.InviteState = InviteState.Incoming;
20 | }
21 |
22 | #region Overrides of AbstractState
23 |
24 | public override void StateChanged()
25 | {
26 | CallInfo info = _context.Call.GetCallInfo();
27 | if (info.State == InviteState.Confirmed)
28 | _context.ChangeState(new ConfirmedInviteState(_context));
29 | else if (info.State == InviteState.Connecting)
30 | _context.ChangeState(new ConnectingInviteState(_context));
31 | else if (info.State == InviteState.Early)
32 | _context.ChangeState(new EarlyInviteState(_context));
33 | else if (info.State == InviteState.Disconnected)
34 | _context.ChangeState(new DisconnectedInviteState(_context));
35 | }
36 |
37 | #endregion
38 | }
39 | }
--------------------------------------------------------------------------------
/pjsip.Interop/Services/CallInfoConverter.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using AutoMapper;
3 | using pjsip4net.Core.Data;
4 | using System.Runtime.InteropServices;
5 |
6 | namespace pjsip.Interop.Services
7 | {
8 | public class CallInfoConverter : ITypeConverter
9 | {
10 | #region Implementation of ITypeConverter
11 |
12 | public CallInfo Convert(ResolutionContext context)
13 | {
14 | var x = (pjsua_call_info) context.SourceValue;
15 | var rx = (CallInfo) context.DestinationValue ?? new CallInfo();
16 |
17 | rx.AccId = x.acc_id;
18 | rx.CallId = x.buf_.call_id;
19 | rx.ConfSlot = x.conf_slot;
20 | rx.ConnectDuration = x.connect_duration;
21 | rx.Id = x.id;
22 | rx.LastStatus = (SipStatusCode) x.last_status;
23 | rx.LastStatusText = x.buf_.last_status_text;
24 | rx.LocalContact = x.buf_.local_contact;
25 | rx.LocalInfo = x.buf_.local_info;
26 | rx.MediaDir = (MediaDirection) x.media_dir;
27 | rx.MediaStatus = (CallMediaState) x.media_status;
28 | rx.RemoteContact = x.buf_.remote_contact;
29 | rx.RemoteInfo = x.buf_.remote_info;
30 | rx.Role = (SipRole) x.role;
31 | rx.State = (InviteState) x.state;
32 | rx.StateText = x.state_text;
33 | rx.TotalDuration = x.total_duration;
34 | return rx;
35 | }
36 |
37 | #endregion
38 | }
39 | }
--------------------------------------------------------------------------------
/pjsip.Interop/TransportTypeExtensions.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core;
3 |
4 | namespace pjsip.Interop
5 | {
6 |
7 | public static class TransportTypeExtensions
8 | {
9 | public static pjsip_transport_type_e ToPjSipTransportType(this TransportType transportType)
10 | {
11 | switch (transportType)
12 | {
13 | case TransportType.Udp:
14 | return pjsip_transport_type_e.PJSIP_TRANSPORT_UDP;
15 | case TransportType.Tcp:
16 | return pjsip_transport_type_e.PJSIP_TRANSPORT_TCP;
17 | case TransportType.Tls:
18 | return pjsip_transport_type_e.PJSIP_TRANSPORT_TLS;
19 | default:
20 | return pjsip_transport_type_e.PJSIP_TRANSPORT_UNSPECIFIED;
21 | }
22 | }
23 |
24 | public static TransportType ToTransportType(this pjsip_transport_type_e transportType)
25 | {
26 | switch (transportType)
27 | {
28 | case pjsip_transport_type_e.PJSIP_TRANSPORT_UDP:
29 | return TransportType.Udp;
30 | case pjsip_transport_type_e.PJSIP_TRANSPORT_TCP:
31 | return TransportType.Tcp;
32 | case pjsip_transport_type_e.PJSIP_TRANSPORT_TLS:
33 | return TransportType.Tls;
34 | default: throw new InvalidOperationException("There is no corresponding TransportType enum value");
35 | }
36 | }
37 | }
38 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Interfaces/ApiProviders/IIMApiProvider.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using pjsip4net.Core.Data;
3 |
4 | namespace pjsip4net.Core.Interfaces.ApiProviders
5 | {
6 | ///
7 | /// An abstraction of service enabling access to pjsua im API
8 | ///
9 | public interface IIMApiProvider
10 | {
11 | BuddyConfig GetDefaultConfig();
12 | //uint pjsua_get_buddy_count();
13 | //bool pjsua_buddy_is_valid(int buddy_id);
14 | //int pjsua_enum_buddies(int[] ids, ref uint count);
15 | //int pjsua_buddy_find(ref pj_str_t uri);
16 | BuddyInfo GetInfo(int buddyId);
17 | //int pjsua_buddy_set_user_data(int buddy_id, IntPtr user_data);
18 | //IntPtr pjsua_buddy_get_user_data(int buddy_id);
19 | int AddBuddyAndGetId(BuddyConfig buddyCfg);
20 | void DeleteBuddy(int buddyId);
21 | void SubscribeBuddyPresence(int buddyId);
22 | void UnsubscribeBuddyPresence(int buddyId);
23 | void UpdatePresence(int buddyId);
24 | //int pjsua_pres_notify(int acc_id, IntPtr srv_pres, pjsip_evsub_state state,
25 | // ref pj_str_t state_str, ref pj_str_t reason, int with_body, pjsua_msg_data msg_data);
26 |
27 | void DumpPresence(bool verbose);
28 | void SendIm(int accId, string to, string mimeType, string content);
29 | void SendIsTyping(int accId, string to);
30 | void SendIsNotTyping(int accId, string to);
31 | }
32 | }
--------------------------------------------------------------------------------
/pjsip4net/Calls/ConfirmedInviteState.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Common.Logging;
3 | using pjsip4net.Core.Data;
4 | using pjsip4net.Core.Utils;
5 |
6 | namespace pjsip4net.Calls
7 | {
8 | ///
9 | /// After ACK is sent/received
10 | ///
11 | internal class ConfirmedInviteState : AbstractState
12 | {
13 | public ConfirmedInviteState(SignallingSession context)
14 | : base(context)
15 | {
16 | LogManager.GetLogger()
17 | .DebugFormat("Call {0} {1}", _context.Call.Id, GetType().Name);
18 | if (_context.IsRinging)
19 | {
20 | _context.CallManager.RaiseRingEvent(_context.Call, false);
21 | _context.IsRinging = false;
22 | }
23 | _context.IsConfirmed = true;
24 | _context.InviteState = InviteState.Confirmed;
25 | }
26 |
27 | #region Overrides of AbstractState
28 |
29 | public override void StateChanged()
30 | {
31 | CallInfo info = null;
32 | bool disposed = false;
33 | try
34 | {
35 | info = _context.Call.GetCallInfo();
36 | }
37 | catch (ObjectDisposedException)
38 | {
39 | disposed = true;
40 | }
41 | if ((info != null && info.State == InviteState.Disconnected) || disposed)
42 | _context.ChangeState(new DisconnectedInviteState(_context));
43 | }
44 |
45 | #endregion
46 | }
47 | }
--------------------------------------------------------------------------------
/pjsip4net/Transport/DefaultVoIPTransportFactory.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Interfaces.ApiProviders;
4 | using pjsip4net.Interfaces;
5 |
6 | namespace pjsip4net.Transport
7 | {
8 | public class DefaultVoIPTransportFactory : IVoIPTransportFactory
9 | {
10 | private ITransportApiProvider _provider;
11 |
12 | public DefaultVoIPTransportFactory(ITransportApiProvider provider)
13 | {
14 | _provider = provider;
15 | }
16 |
17 | #region Implementation of IVoIPTransportFactory
18 |
19 | public IVoIPTransport CreateTransport(TransportType transportType)
20 | {
21 | switch (transportType)
22 | {
23 | case TransportType.Udp:
24 | return new UdpTransport(_provider);
25 | case TransportType.Tcp:
26 | return new TcpTransport(_provider);
27 | case TransportType.Tls:
28 | return new TlsTransport(_provider);
29 | default:
30 | return new UdpTransport(_provider);
31 | }
32 | }
33 |
34 | public IVoIPTransport CreateTransport(TransportType transportType, TransportConfig config)
35 | {
36 | var tpt = CreateTransport(transportType);
37 | using (((Initializable)tpt).InitializationScope())
38 | if (config != null) tpt.SetConfig(config);
39 | return tpt;
40 | }
41 |
42 | #endregion
43 | }
44 | }
--------------------------------------------------------------------------------
/pjsip.Interop/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("pjsip.Interop")]
9 | [assembly: AssemblyDescription("")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("DoxWox")]
12 | [assembly: AssemblyProduct("pjsip.Interop")]
13 | [assembly: AssemblyCopyright("Copyright © RobertT 2010")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(false)]
21 |
22 | // The following GUID is for the ID of the typelib if this project is exposed to COM
23 | [assembly: Guid("fe1b74e7-4ca2-4730-aea6-dd547810e5e4")]
24 |
25 | // Version information for an assembly consists of the following four values:
26 | //
27 | // Major Version
28 | // Minor Version
29 | // Build Number
30 | // Revision
31 | //
32 | // You can specify all the values or you can default the Build and Revision Numbers
33 | // by using the '*' as shown below:
34 | // [assembly: AssemblyVersion("1.0.*")]
35 | [assembly: AssemblyVersion("1.4.*")]
36 | [assembly: AssemblyFileVersion("1.4.*")]
37 |
--------------------------------------------------------------------------------
/pjsip4net.Core/Interfaces/ApiProviders/IAccountApiProvider.cs:
--------------------------------------------------------------------------------
1 | using pjsip4net.Core.Data;
2 |
3 | namespace pjsip4net.Core.Interfaces.ApiProviders
4 | {
5 | ///
6 | /// An abstraction of service enabling access to pjsua account API
7 | ///
8 | public interface IAccountApiProvider
9 | {
10 | AccountConfig GetDefaultConfig();
11 | //void pjsua_acc_config_default(pjsua_acc_config cfg);
12 | //uint pjsua_acc_get_count();
13 | bool IsValidAccount(int accId);
14 | void SetDefaultAccount(int accId);
15 | int GetDefaultAccountId();
16 | int AddAccountAndGetId(AccountConfig accCfg, bool isDefault);
17 | int AddLocalAccountAndGetId(int transportId, bool isDefault);
18 | //int pjsua_acc_set_user_data(int accId, IntPtr user_data);
19 | //IntPtr pjsua_acc_get_user_data(int acc_id);
20 | void DeleteAccount(int accId);
21 | //int pjsua_acc_modify(int acc_id, pjsua_acc_config acc_cfg);
22 | void SetAccountOnlineStatus(int accId, bool isOnline);
23 | void SetAccountOnlineStatus(int accId, bool isOnline, RpidElement pr);
24 | void SetAccountRegistration(int accId, bool renew);
25 | AccountInfo GetInfo(int accId);
26 | //int pjsua_enum_accs(int[] ids, ref uint count);
27 | //int pjsua_acc_enum_info(pjsua_acc_info[] info, ref uint count);
28 | int GetBestSuitingAccountIdForUrl(string url);
29 | void SetTransport(int accId, int tpId);
30 | }
31 | }
--------------------------------------------------------------------------------
/lib/NAnt/extensions/common/2.0/NAnt.MSBuild.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | NAnt.MSBuild
5 |
6 |
7 |
8 |
9 | Functions to return information for MSBuild system.
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 | Test whether project is VS2005 project and could be built using <msbuild>
18 |
19 | The name or path of the project file (csproj, vbproj, ...).
20 |
21 | True, if it is msbuild project, False otherwise.
22 |
23 |
24 |
25 |
26 | Initialize is guaranteed to be called by MSBuild at the start of the build
27 | before any events are raised.
28 |
29 |
30 |
31 |
32 | Analyses Microsoft Visual Studio .NET 2005 (Whidbey) solution files.
33 |
34 |
35 |
36 |
37 |
--------------------------------------------------------------------------------
/pjsip4net/Interfaces/IAccount.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Net;
4 | using pjsip4net.Accounts;
5 | using pjsip4net.Core.Data;
6 | using pjsip4net.Core.Interfaces;
7 |
8 | namespace pjsip4net.Interfaces
9 | {
10 | ///
11 | /// Provides methods to connect to SIP servers & properties reflecting registration state.
12 | ///
13 | public interface IAccount : IInitializable
14 | {
15 | int Id { get; }
16 | string AccountId { get; set; }
17 | NetworkCredential Credential { get; set; }
18 | SrtpRequirement UseSrtp { get; set; }
19 | int SecureSignaling { get; set; }
20 | int Priority { get; set; }
21 | string RegistrarUri { get; set; }
22 | string RegistrarDomain { get; }
23 | string RegistrarPort { get; }
24 | bool PublishPresence { get; set; }
25 | ICollection Proxies { get; }
26 | uint RegistrationTimeout { get; set; }
27 | uint KeepAliveInterval { get; set; }
28 | bool? IsOnline { get; }
29 | string OnlineStatusText { get; }
30 | bool IsRegistered { get; }
31 | bool? IsDefault { get; }
32 | string Uri { get; }
33 | bool? HasRegistration { get; }
34 | int? Expires { get; }
35 | SipStatusCode? StatusCode { get; }
36 | string StatusText { get; }
37 | IVoIPTransport Transport { get; set; }
38 |
39 | void SetConfig(AccountConfig config);
40 | void PublishOnline(string note);
41 | void RenewRegistration();
42 | void Unregister();
43 | }
44 | }
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/given_bcl_extensions.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Linq;
3 | using NUnit.Framework;
4 | using pjsip4net.Core.Utils;
5 |
6 | namespace pjsip4net.Tests
7 | {
8 | // ReSharper disable InconsistentNaming
9 | [TestFixture]
10 | public class given_bcl_extensions
11 | {
12 | [Test]
13 | public void when_growWithDefaultToCalled_on_empty_collection_should_grow_it_up_to_specified_number_of_items()
14 | {
15 | var result = Enumerable.Empty().GrowWithDefaultToTheSizeOf(3);
16 | Assert.That(result.Count(), Is.EqualTo(3));
17 | }
18 |
19 | [Test]
20 | public void when_growWithDefaultToCalled_on_collection_with_3_items_to_grow_to_3_should_not_do_anything()
21 | {
22 | var result = Enumerable.Repeat(new Int32(), 3).GrowWithDefaultToTheSizeOf(3);
23 | Assert.That(result.Count(), Is.EqualTo(3));
24 | }
25 |
26 | [Test, ExpectedException(typeof(ArgumentOutOfRangeException))]
27 | public void when_growWithDefaultToCalled_with_grow_to_argument_less_then_the_size_of_collection_should_throw_exception()
28 | {
29 | Enumerable.Repeat(new Int32(), 3).GrowWithDefaultToTheSizeOf(2);
30 | Assert.Fail();
31 | }
32 |
33 | [Test]
34 | public void when_growWithDefaultTo_called__original_collection_should_go_first()
35 | {
36 | var result = Enumerable.Repeat(2, 1).GrowWithDefaultToTheSizeOf(2);
37 | Assert.That(result.First(), Is.EqualTo(2));
38 | }
39 | }
40 | // ReSharper restore InconsistentNaming
41 | }
--------------------------------------------------------------------------------
/pjsip4net.Core/Data/AccountConfig.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using System.Net;
3 |
4 | namespace pjsip4net.Core.Data
5 | {
6 | public class AccountConfig
7 | {
8 | private List _proxy = new List(8);
9 | private List _cred_info = new List(8);
10 |
11 | public bool IsDefault { get; set; }
12 |
13 | public object UserData { get; set; }
14 | public int Priority { get; set; }
15 | public string Id { get; set; }
16 | public string RegUri { get; set; }
17 | public bool IsPublishEnabled { get; set; }
18 | public string PidfTupleId { get; set; }
19 | public string ForceContact { get; set; }
20 | public string ContactParams { get; set; }
21 | public string ContactUriParams { get; set; }
22 | public bool Require100Rel { get; set; }
23 | public bool RequireTimer { get; set; }
24 | public uint RegTimeout { get; set; }
25 | public int TransportId { get; set; }
26 | public bool AllowContactRewrite { get; set; }
27 | public uint KaInterval { get; set; }
28 | public string KaData { get; set; }
29 | public SrtpRequirement UseSrtp { get; set; }
30 | public int SrtpSecureSignaling { get; set; }
31 |
32 | public List Proxy
33 | {
34 | get { return _proxy; }
35 | set { _proxy = value; }
36 | }
37 |
38 | public List Credentials
39 | {
40 | get { return _cred_info; }
41 | set { _cred_info = value; }
42 | }
43 | }
44 | }
--------------------------------------------------------------------------------
/pjsip4net/Accounts/UnknownStatusState.cs:
--------------------------------------------------------------------------------
1 | using Common.Logging;
2 | using pjsip4net.Core.Data;
3 | using pjsip4net.Core.Utils;
4 |
5 | namespace pjsip4net.Accounts
6 | {
7 | ///
8 | /// After unknown status recieved
9 | ///
10 | internal class UnknownStatusState : AbstractState
11 | {
12 | public UnknownStatusState(RegistrationSession context, SipStatusCode code, string statusText)
13 | : base(context)
14 | {
15 | _context.IsRegistered = false;
16 | StatusCode = code;
17 | StatusText = statusText;
18 | var logger = LogManager.GetLogger();
19 | logger.DebugFormat("Account {0} UnknownStatusState", _context.Account.Id);
20 | logger.Debug(StatusText);
21 | }
22 |
23 | public SipStatusCode StatusCode { get; private set; }
24 | public string StatusText { get; private set; }
25 |
26 | public override void StateChanged()
27 | {
28 | AccountInfo info = _context.Account.GetAccountInfo();
29 | if (info.Status == SipStatusCode.Ok)
30 | _context.ChangeState(new RegisteredAccountState(_context));
31 | else if (info.Status == SipStatusCode.RequestTimeout)
32 | _context.ChangeState(new TimedOutAccountRegistrationState(_context));
33 | else if (info.Status == SipStatusCode.Trying)
34 | _context.ChangeState(new RegisteringAccountState(_context));
35 | else
36 | _context.ChangeState(new UnknownStatusState(_context, info.Status, info.StatusText));
37 | }
38 | }
39 | }
--------------------------------------------------------------------------------
/pjsip.Interop/Version_1_4_ComponentConfigurator.cs:
--------------------------------------------------------------------------------
1 | using AutoMapper;
2 | using pjsip.Interop.ApiProviders;
3 | using pjsip.Interop.Interfaces;
4 | using pjsip.Interop.Services;
5 | using pjsip4net.Core.Interfaces;
6 | using pjsip4net.Core.Interfaces.ApiProviders;
7 | using pjsip4net.Core.Utils;
8 |
9 | namespace pjsip.Interop
10 | {
11 | // ReSharper disable InconsistentNaming
12 | public class Version_1_4_ComponentConfigurator : IConfigureApi
13 | // ReSharper restore InconsistentNaming
14 | {
15 | #region Implementation of IConfigureComponents
16 |
17 | public void Configure(IContainer container)
18 | {
19 | Helper.GuardNotNull(container);
20 | RegisterMappingServices(container);
21 | RegisterVoIPServices(container);
22 | }
23 |
24 | #endregion
25 |
26 | private void RegisterMappingServices(IContainer container)
27 | {
28 | container
29 | .RegisterAsSingleton(Mapper.Engine)
30 | .RegisterAsSingleton();
31 | }
32 |
33 | private void RegisterVoIPServices(IContainer container)
34 | {
35 | container.RegisterAsSingleton()
36 | .RegisterAsSingleton()
37 | .RegisterAsSingleton()
38 | .RegisterAsSingleton()
39 | .RegisterAsSingleton()
40 | .RegisterAsSingleton();
41 | }
42 | }
43 | }
--------------------------------------------------------------------------------
/Tests/Unit/pjsip4net.Tests/given_a_default_media_configurator.cs:
--------------------------------------------------------------------------------
1 | using Moq;
2 | using NUnit.Framework;
3 | using pjsip4net.Configuration;
4 | using pjsip4net.Core.Data;
5 | using pjsip4net.Interfaces;
6 | using pjsip4net.Media;
7 |
8 | namespace pjsip4net.Tests
9 | {
10 | // ReSharper disable InconsistentNaming
11 | [TestFixture]
12 | public class given_a_default_media_configurator : given_a_component_configurator
13 | {
14 | [Test]
15 | public void when_configure_is_called__should_register_default_conference_bridge_as_singleton()
16 | {
17 | when_configure_called();
18 | _container.Verify(x => x.RegisterAsSingleton());
19 | }
20 |
21 | [Test]
22 | public void when_configure_is_called__should_register_default_media_manager_with_internal_interface_as_singleton()
23 | {
24 | when_configure_called();
25 | _container.Verify(x => x.RegisterAsSingleton());
26 | }
27 |
28 | [Test]
29 | public void when_configure_is_called__should_register_wavPlayer_as_transient()
30 | {
31 | when_configure_called();
32 | _container.Verify(x => x.Register());
33 | }
34 |
35 | [Test]
36 | public void when_configure_is_called__should_register_codecInfo_as_transient()
37 | {
38 | when_configure_called();
39 | _container.Verify(x => x.Register());
40 | }
41 | }
42 | // ReSharper restore InconsistentNaming
43 | }
--------------------------------------------------------------------------------