Re: [Mono-list] SQLDMO

2008-01-15 Thread Andrés G. Aragoneses [ knocte ]
shawn vose escribió:
> 
> Curious to know if there is any support for the SQLDMO namespace. My 
> guess is a big no since it is using COM interop
> 
> If no are there any plans on creating a similar set of libs?
> 

Have you tried using the DLL with Mono? Anyway, DMO is deprecated by SMO.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] SharpOS 0.0.1 Release

2008-01-03 Thread Andrés G. Aragoneses [ knocte ]
William Lahti escribió:
> 'm happy to announce that we have released version 0.0.1 of SharpOS,
> including our AOT compiler and a basic kernel with an interactive
> shell. This is a proof of concept release intended to gather
> awareness, support and participation from community members, so if you
> are interested in working on this project we encourage you to sign up
> for our mailing list. For those of you who don't know about SharpOS,
> it is a project to write an operating system purely in C#, which was
> actually spawned from the "Operating system in C#" thread on
> mono-devel-list. Although we don't have object instantiation or meta
> data embedding in our kernel yet, the release proves clearly that the
> concept is possible. Our next milestone focuses on supporting managed
> code in the kernel, as well as using that managed code to improve our
> current systems as much as possible.
> 
> Our wiki and project management suite is at http://sharpos.org/.  Our
> file releases area at SourceForge
> (http://sourceforge.net/project/platformdownload.php?group_id=196652)
> contains tarballs and zips with source code, binaries, and disk images
> for testing. We've also got ISO images for trying SharpOS on real
> computers (that don't have floppy drives, that is), as well as the
> usual configurations for Bochs, VMWare, and Virtual PC.
> 
> And have a wonderful new year everyone!
> 
> PS: I've had a lot of trouble posting to the list because Postfix says
> the dates on the email are in the future??
> 
> 

I'm curious, do you have rough numbers about performance loss compared 
to a non-managed OS like Linux (I guess the difference is huge right 
now, but what do you think you can reach if it begins to get optimized?).

BTW, does this approach have the advantage of a micro-kernel safe 
approach or is it only safe from the point of view of memory leaks 
(thanks to the garbage collector)?

Thanks in advance, and congratulations for this great project.

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Looking for an mplayer (or similar) wrapper

2008-01-02 Thread Andrés G. Aragoneses [ knocte ]
Oli Warner escribió:
> Super! Yeah they use GStreamer (which I completely forgot all about) and 
> there's a GStreamer-sharp mono project!
> 
> http://www.mono-project.com/Gstreamer
> 
> Fantastic! Thank you for your help.
> 

Wasn't Gstreamer# died? BTW, there's also a very interesting discussion 
on Banshee list about doing a replacement: MonoMedia [1].

Regards,

Andrés

[1] http://mail.gnome.org/archives/banshee-list/2007-December/msg00025.html

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mono C# versus Java 6 -server performance

2007-11-29 Thread Andrés G. Aragoneses [ knocte ]
Robert Hulme escribió:
> Hi,
> 
> I have recently been part of a discussion with colleagues about the 
> merits of C# versus Java. I am of the opinion that C# is a superior 
> language, but my colleagues questioned whether the performance is 
> comparable on Linux (which is what we use here at EBI).
> 
> I had a look on the Language Shootout, comparing Mono 1.2.5 with Java 6 
> -server. 
> http://shootout.alioth.debian.org/gp4/benchmark.php?test=all&lang=csharp
> 
> In almost all the benchmarks Mono C# was significantly slower than Java 6.
> 
> I downloaded some of the benchmarks to see if I could reproduce the 
> results on my machine (Mono JIT compiler version 1.2.3.1 / Java 6). The 
> results were the same. Twiddling with mono / mcs flags didn't seem to 
> make a difference.
> 
> I was wondering if anyone had any insights in to why this is, whether it 
> is a CIL/C# issue or is specific to the Mono implementation, and whether 
> there are any plans to bring Mono performance in line with Java performance.

Can the test be done with:
- MS.NET, to have more contrast?
- A more recent Mono version (as on last ones I believe that 
performance/memory issues have been corrected).

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Gecko WebControl error handling

2007-11-28 Thread Andrés G. Aragoneses [ knocte ]
Piotr Budny escribió:
> Hello,
> when doing:
> 
> control = new WebControl ();
> control.LoadUrl("http://some.non.existent.host";);
> 
> the "some.non.existent.host could not be found. Please check the name and try 
> again." dialog appears.
> 
> Is there any way to get rid of that dialog and manage that error within own 
> code? 
> I'd like WebControl actually doesn't show & care about errors.

That's a thing that also interests me as a developer/user of the Gecko# 
control. But in the past I played with it a little and I seem to 
remember that those dialogs are XUL based, so maybe the whole lib needs 
an architectural review in order not to include any XUL technology, 
right? Can any mono/mozilla hacker bring some light here?

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] MonoDevelop user survey: beyond 1.0

2007-11-08 Thread Andrés G. Aragoneses [ knocte ]
Lluis Sanchez escribió:
> MonoDevelop 1.0 is just around the corner, and it is mostly feature
> frozen. Now it is time to start thinking beyond 1.0. We have published a
> survey with the goal of getting a more clear view of what MonoDevelop is
> being used for, and what features are the most requested. This will help
> us planning the future directions of the project. 
> 
> This is the url of the survey: 
> http://surveys.mjhutchinson.com/index.php?sid=95822&lang=en
> 
> Thank you for your feedback!
> The MonoDevelop team.


This is an excellent idea, congratulations!
It would be interesting to show the overall results of the survey after 
some days.

Regards,

Andrés  [ knocte ]

-- 


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Any memory leak in this code snippet?

2007-11-04 Thread Andrés G. Aragoneses [ knocte ]
Could you advise me if there could be any memory leak in this C# code 
snippet?:

http://monoport.com/5305

As I understand, I have closed all risky objects: EventWaitHandle, and 
Timer. Do I need to unregister the Elapsed event handler with the 
delegate ( -= ) before disposing the timer? or it isn't necessary?

Thanks in advance,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] [Mono-dev] MonoSummit: Planning the Sessions

2007-10-29 Thread Andrés G. Aragoneses [ knocte ]
Mads Bondo Dydensborg escribió:
> fredag 26 Oktober 2007 skrev Miguel de Icaza:
>> Hey folks,
>>
>> Am looking for ideas for topics that developers would be interested
>> in hearing about at the Mono Summit.   
> 
> I would be happy to hear about debugging applications with mono, the state of 
> the debugger, etc.
> 
> Also, in relation to this, debugging mono itself: when you _really_ think 
> what 
> you observe is not a bug in your program, how to go about checking mono 
> against the C# standard, MS implementation, whatever.

I would love that BoF!
Also I am thinking about another one that could explain how to run the 
unit tests successfully across many operating systems. I'm interested in 
contributing some patches but first I have to understand how to launch 
these tests in MS.NET using Cygwin, in order to see if my unit tests are 
correct or not. I don't have enough time to dive into the loop of 
test-error-test-error to find it out (maybe this could be a good section 
in the already existing planned activity by Marcos Cobeña.. I don't know).

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] bug casting to a List

2007-10-01 Thread Andrés G. Aragoneses [ knocte ]
Daniel Soto escribió:
> Andrés G. Aragoneses [ knocte ] escribió:
>> Have you tested that code with MS.NET? (If it doesn't work there too, 
>> it's likely not a bug.)
>>   
> Yup! The code runs in MS.NET. In Windows Server 2003 runs fine.
> 
> It is a bug?

It's likely a bug, so http://www.mono-project.com/Bugs

Thanks ;)

Andrés  [ knocte ]

-- 


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Crazy generic dictionary?

2007-10-01 Thread Andrés G. Aragoneses [ knocte ]
Andrés G. Aragoneses [ knocte ] escribió:
> Robert Jordan escribió:
>> [...]
>> Scratch this. I didn't notice that you were using subclasses.
> 

Finally I've come out with this solution, in case someone is interested:

 class IrmDictionary : Dictionary
 {
 public void Add(IList t) where K:T
 {
 if (t == null)
 {
 throw new ArgumentNullException("t");
 }
 if (t.Count > 0)
 {
 this[t[0].GetType()] = (IList)t;
 }
 }
 }

(I know the 't[0]' seems hackish, but is more readable than obtaining 
the type by reflection; and also I don't need the list if it's empty, so 
I don't mind having to access to the first element.)


Maybe we could have here a possible additional item for the wishlist of 
next C# version:

 class IrmDictionary : Dictionary>
 {
 public void Add(IList t) where K:T
 {
 if (t == null)
 {
 throw new ArgumentNullException("t");
 }
 if (t.Count > 0)
 {
 this[t[0].GetType()] = t;
 }
 }
 }

The problem is the relation between the two 'K' letters. I don't if it 
could be feasible to add this feature.

Thanks for all the people replying to this thread. It's been interesting.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Crazy generic dictionary?

2007-10-01 Thread Andrés G. Aragoneses [ knocte ]
Robert Jordan escribió:
> [...]
> Scratch this. I didn't notice that you were using subclasses.


If I didn't use them, I wouldn't be able to store more than one object 
either :)

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Crazy generic dictionary?

2007-09-30 Thread Andrés G. Aragoneses [ knocte ]
Robert Jordan escribió:
> Andrés G. Aragoneses [ knocte ] wrote:
>> Robert Jordan escribió:
>>> Andrés G. Aragoneses [ knocte ] wrote:
>>>> Today I've come out with this wish:
>>>>
>>>> Dictionary> InternalCollection;
>>>>
>>>>
>>>> Of course, the compiler tells me an error, but I would want to know if I 
>>>> can make this kind of collection with C# generics, in order to obtain 
>>>> syntatic sugar and type safety, I mean:
>>>>
>>>> //compilation should succeed only if oMyObj is TypeX:T
>>>> InternalCollection.Add(typeof(TypeX), oMyObj);
>>>>
>>>> Any thoughts?
>>> class FooDictionary : Dictionary
>>> {
>>> public void Add (T t)
>>> {
>>> this [typeof(T)] = t;
>>> }
>>> }
>>>
>> But that would only allow adding one object:
> 
> 
> Well, then use that slightly modified Add method:
> 
>   public void Add (T t)
>   {
>   if (t == null)
>   throw new ArgumentNullException ("t");
>   this [t.GetType ()] = t;
>   }
> 

Ok! But if I modify it to use lists, I get a compiler error:

class FooDictionary : Dictionary>
{
 public void Add (List t)
 {
 if (t == null)
 {
 throw new ArgumentNullException("t");
 }
 if (t.Count > 0)
 {
 this[t[0].GetType()] = t;
 }
 }
}

...

FooDictionary foo = new FooDictionary();
foo.Add(new List());

Error   11  Argument '1': cannot convert from 
'System.Collections.Generic.List' to 
'System.Collections.Generic.List'

However, it should allow it because subtypeA inherits from mytype, 
right? I think I've reached a limitation of .NET generics, which I think 
I read about here[1] :(

Thanks,

Andrés  [ knocte ]

-- 
[1] http://www.jprl.com/Blog/archive/development/2007/Aug-31.html

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Crazy generic dictionary?

2007-09-30 Thread Andrés G. Aragoneses [ knocte ]
Robert Jordan escribió:
> Andrés G. Aragoneses [ knocte ] wrote:
>> Today I've come out with this wish:
>>
>> Dictionary> InternalCollection;
>>
>>
>> Of course, the compiler tells me an error, but I would want to know if I 
>> can make this kind of collection with C# generics, in order to obtain 
>> syntatic sugar and type safety, I mean:
>>
>> //compilation should succeed only if oMyObj is TypeX:T
>> InternalCollection.Add(typeof(TypeX), oMyObj);
>>
>> Any thoughts?
> 
> class FooDictionary : Dictionary
> {
>   public void Add (T t)
>   {
>   this [typeof(T)] = t;
>   }
> }
> 

But that would only allow adding one object:

class mytype
{
   ...
}

class subtypeA : mytype
{
   ...
}


class subtypeB : mytype
{
   ...
}

FooDictionary foo = new FooDictionary();
foo.Add(new subtypeA());
foo.Add(new subtypeB());

This last addition would remove previous object because we are using 
typeof(mytype) instead of typeof(subtype), am I right?


Besides, what I want to store is a List, not an object (I know, it 
wasn't clear in first email), so my wish would be:

FooDictionary foo = new FooDictionary();
List listA = new List();
List listB = new List();
listA.Add(new subtypeA());
listB.Add(new subtypeB());
foo.Add(listA);
foo.Add(listB);

Thanks for your answer,

Andrés  [ knocte ]

-- 


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] bug casting to a List

2007-09-29 Thread Andrés G. Aragoneses [ knocte ]
Daniel Soto escribió:
> Hi All.
> 
> When i try to cast to a Generic.List from object type, i get the 
> exception
> 
> System.InvalidCastException: Cannot cast from source type to destination type.
> 
> The code that throws the exception, here
> 
> System.Collections.Generic.List myList;
> myList = (System.Collections.Generic.List)Session["ListInMemory"];
> 
> The same occurs if i try to cast to ArrayList, or an Array of object.
> 
> 
> This is a bug? In the bug list in the main page of mono, it says that it's 
> resolved, 
> but to me still doest not work :-(
> 
> Either i can to report this bug, my novell account says that my access 
> is forbidden (huh? but i finish creating it!!).
> 
> There are another way to passing the values from object to my List?
> 
> Best regards.
> 

Have you tested that code with MS.NET? (If it doesn't work there too, 
it's likely not a bug.)

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Crazy generic dictionary?

2007-09-29 Thread Andrés G. Aragoneses [ knocte ]
Today I've come out with this wish:

Dictionary> InternalCollection;


Of course, the compiler tells me an error, but I would want to know if I 
can make this kind of collection with C# generics, in order to obtain 
syntatic sugar and type safety, I mean:

//compilation should succeed only if oMyObj is TypeX:T
InternalCollection.Add(typeof(TypeX), oMyObj);

Any thoughts?

Thanks in advance.

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Packaged .NET apps for Mono: Call for Ideas.

2007-09-21 Thread Andrés G. Aragoneses [ knocte ]
Joseph Hill escribió:
> Having Mono applications packaged so that they can easily be sampled by .NET 
> developers would be a big win.

I agree.


> There should be a ton of these, but to begin with, I would consider the 
> following:
> * The ASP.NET Starter Kits
> * mojoPortal (probably the SQLite version would be the simplest candidate).
> * Paint.NET
> 
> * NCover
> * NProf
> * log4net
> * NHibernate
> * Castle Project (MonoRail, ActiveRecord, etc)
> * CruiseControl.NET
> * Phalanger


I vote for these ones too, and some more:

* NLog
* ReadableRex
* DotNetOpenId
* SharpZipLib
* NetSpell
* BitRock InstallBuilder
* Maverick.NET
* DB4O
* DotNetOpenMail
* OpenSmtp.Net
* OpenPop.Net
* ActiveMQ
* Deveel Regex
* NPlot
* NChart
* Spring.NET
* AspectSharp
* iTextSharp
* NFop

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Gecko WebControl in a WinForm, possible?

2007-09-13 Thread Andrés G. Aragoneses [ knocte ]
R. K. Wijayaratne escribió:
> Thanks for your feedback. However I am ideally wanting to target Mono 
> 1.x platform if possible.

I think you're confusing terms. When I referred to 2.0 profile, I was 
referring at the .NET version. Mono 1.2.x can be used for targeting the 
2.0 profile or the 1.1 profile (for example for using generics).


> I created a Glade form with a Gecko WebControl, however my WinForms app 
> is MDI based so it does not seem possible to add the Glade form to the 
> parent WinForm.
> The only other option that I can think of is taking the Mono 2.x 
> WebControl and seeing if I can adapt it to work with Mono 1.x.

As I said above, I guess you're confusing things. There's no Mono 2.x or 
Mono 1.x.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Gecko WebControl in a WinForm, possible?

2007-09-08 Thread Andrés G. Aragoneses [ knocte ]
R. K. Wijayaratne escribió:
> Hello everyone,
> 
> I was wondering if it was possbile to use a gecko WebControl in a purely 
> WinForms based application under Mono?
> 

It's not necessary, you could use the WebControl class from WinForms 
(2.0 profile), but it's implemented on SVN (and will be available in 
next mono version).

More info:
http://tirania.org/blog/archive/2007/Sep-04.html

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] .NET 2.0 WebService XML serialization format

2007-08-11 Thread Andrés G. Aragoneses [ knocte ]
Hello,

I have observed that, when writing a WebService using .NET 2.0, if a
[WebMethod] returns an object instead of a primitive type, the
XmlFormatter is used for serializing it.

But, how can I configure the webservice to use the SoapFormatter instead?

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Visual Studio 2005 .NET solution compiling on Linux

2007-08-01 Thread Andrés G. Aragoneses [ knocte ]
Ankit Jain escribió:
>> Hasn't the capability of building VS2005 sln files be shared between
>> xbuild and MD? If not, why?
> 
> No, its not shared currently. At the time this capability was added to MD,
> our MSBuild api wasn't complete enough to support that. But Marek Sieradzki
> has fixed that, and he infact had a patch to add the relevant support to MD,
> which might be integrated later.

Thanks Ankit. This interests me because I plan to setup a continuous 
integration system that builds solutions everytime there is a commit. I 
hope to help improve all of this by notifying all bugs I find about 
incompatibilities between msbuild and xbuild.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Visual Studio 2005 .NET solution compiling on Linux

2007-08-01 Thread Andrés G. Aragoneses [ knocte ]
Ankit Jain escribió:
>> 4.  I tried converting the Visual Studio 2005 solution using
>> MonoDevelop, but this failed.  Not really what I wanted to do anyway, as I
>> wanted to use the same files on both Windows and Linux.
> 
> You can use MonoDevelop to directly build the VS2005 solution. Either
> from the GUI or from the command line like -
>mdtool build --buildfile:foo.sln
> 
> MD can directly work with VS2005 solutions, no conversion to any other
> format required.

Hasn't the capability of building VS2005 sln files be shared between 
xbuild and MD? If not, why?

Thanks in advance,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] [Follow-up] Re: Recursive XML serialization? XML serialization of cyclic objects?

2007-07-19 Thread Andrés G. Aragoneses [ knocte ]
Just a follow-up to this old thread (sorry if it gets re-posted):

(http://lists.ximian.com/pipermail/mono-list/2007-January/033886.html)

> Andrés G. Aragoneses [ knocte ] wrote:
>> > Robert Jordan escribió:
>>>> >>> How can I send "myObject" via XML webservice for consumption? I am 
>>>> >>> aware
>>>> >>> that this is not possible to be XML-serialized with .NET1.1 but, can I
>>>> >>> do it with 2.0 or Indigo?
>>> >> I'm not aware of any Web Service standard allowing that
>>> >> kind of cycles.
>> > 
>> > Indigo (WCF) seems to support it! :
>> > 
>> > http://groups.google.com/group/microsoft.public.dotnet.languages.csharp/browse_thread/thread/4e76b309c00eaf49/9235fd20edc55d7f#hdropenedd02799e0c3b43525
>> > 
>> > I will then be eager for olive to be released :D
> It is possibly only with NetDataContractSerializer and cannot be
> done with DataContractSerializer. Since NetDataContractSerializer
> sucks in general (there is no point of using it instead of runtime
> serialization), the priority is low at my hands. Indigo's "design
> by contract" concept is becomes almost implicit (== practically
> broken) when ISerializable objects are involved.
> 
> Probably you could try runtime serialization with Soap formatter:
> System.Runtime.Serialization.Formatters.Soap
> 
> Atsushi Eno


I've been so (lazy|busy) these months to not have tested this until now; 
and it just works! (Thanks Atsushi.) So I'm going ahead with the 
SoapFormatter.

However, I have found out that a .NET2.0 WebService by default 
serializes my objects using normal XmlSerializer. Is there any 
configuration setting for it to use the SoapFormatter when returning a 
[Serializable] object from my [WebMethod]?

BTW, I would also like to call a "SanityCheck()" method for every object 
that is returned from my webmethods before sending them. Can this be 
done without AOP?

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Recursive XML serialization? XML serialization of cyclic objects?

2007-07-19 Thread Andrés G. Aragoneses [ knocte ]
Just a follow-up to this old thread:

(http://lists.ximian.com/pipermail/mono-list/2007-January/033886.html)

> Andrés G. Aragoneses [ knocte ] wrote:
>> > Robert Jordan escribió:
>>>> >>> How can I send "myObject" via XML webservice for consumption? I am 
>>>> >>> aware
>>>> >>> that this is not possible to be XML-serialized with .NET1.1 but, can I
>>>> >>> do it with 2.0 or Indigo?
>>> >> I'm not aware of any Web Service standard allowing that
>>> >> kind of cycles.
>> > 
>> > Indigo (WCF) seems to support it! :
>> > 
>> > http://groups.google.com/group/microsoft.public.dotnet.languages.csharp/browse_thread/thread/4e76b309c00eaf49/9235fd20edc55d7f#hdropenedd02799e0c3b43525
>> > 
>> > I will then be eager for olive to be released :D
> It is possibly only with NetDataContractSerializer and cannot be
> done with DataContractSerializer. Since NetDataContractSerializer
> sucks in general (there is no point of using it instead of runtime
> serialization), the priority is low at my hands. Indigo's "design
> by contract" concept is becomes almost implicit (== practically
> broken) when ISerializable objects are involved.
> 
> Probably you could try runtime serialization with Soap formatter:
> System.Runtime.Serialization.Formatters.Soap
> 
> Atsushi Eno


I've been so (lazy|busy) these months to not have tested this until now; 
and it just works! (Thanks Atsushi.) So I'm going ahead with the 
SoapFormatter.

However, I have found out that a .NET2.0 WebService by default 
serializes my objects using normal XmlSerializer. Is there any 
configuration setting for it to use the SoapFormatter when returning a 
[Serializable] object from my [WebMethod]?

BTW, I would also like to call a "SanityCheck()" method for every object 
that is returned from my webmethods before sending them. Can this be 
done without AOP?

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mono summit, options.

2007-07-18 Thread Andrés G. Aragoneses [ knocte ]
Néstor Salceda escribió:
> El mié, 18-07-2007 a las 10:00 +0200, Marcos Cobeña Morián escribió:
>> Hello Miguel,
>>
>> If your team finally decide to go for Madrid option (even Seville
>> could be nice :-P), some mates and I'd help looking for a place to
>> host the summit (one of the campus available at this city would be
>> nice). Even more, I involve myself in finding an University. :-)
> 
> Yep Marcos, I also can help you finding the place :)
> 

Hey, here's another helping hand from Madrid. I know yet some teachers 
from the college where I studied (www.fi.upm.es), I will ask them so, 
what are the approximate expected dates for the event?



Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Native Mono UI widgets

2007-07-11 Thread Andrés G. Aragoneses [ knocte ]
Jonathan Pobst escribió:
> Ah, I guess it's purely philosophical then.  Basically boiling down to 
> "Do we really need *another* toolkit"?  We have to have WinForms to 
> provide compatibility with the .Net framework.  And we need GTK# to make 
> Mono a great choice for Linux (and somewhat cross-platform) apps.  (And 
> there are others like QT and wxNet and Cocoa#.)  So what would another 
> toolkit bring?
> 
> Writing an entire toolkit is hard and expensive.  WinForms has been 
> under development for probably 4 years having up to 6 people working on 
> it full-time as well as plenty of contributors.
> 
> I don't really know of any benefit to making another one.  WinForms is 
> already "Mono native" in that it's fully done with System.Drawing.  It 
> seems like a new one would simply take the WinForms widgets and change 
> the API simply for the sake of being different.  :)

I guess he's not asking 'why not doing another toolkit using S.D.' but 
'why not redo Gtk# using S.D.'. I guess the disadvantages of that would 
be less performance and much time needed to write it, but in the end it 
would be a managed toolkit and many problems that Gtk# has already, 
would blow, don't you think?

Regards,

Andrés  [ knocte ]

-- 
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ANNOUNCE: Mono.Addins 0.2

2007-07-10 Thread Andrés G. Aragoneses [ knocte ]
Andrés G. Aragoneses [ knocte ] escribió:
> Lluis Sanchez escribió:
>> Hi,
>>
>> I'm pleased to announce the release of Mono.Addins 0.2.
>>
> 
> Hi Lluis, very interesting release!
> 
> With which license is covered this library? It would be interesting to 
> specify this on the info page.
> 

Hugh, now I see that it's specified in another document:

http://www.mono-project.com/Introduction_to_Mono.Addins

Thanks anyway. I think I'm going to use it in my next project.

Regards,

Andrés  [ knocte ]

-- 


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ANNOUNCE: Mono.Addins 0.2

2007-07-07 Thread Andrés G. Aragoneses [ knocte ]
Lluis Sanchez escribió:
> Hi,
> 
> I'm pleased to announce the release of Mono.Addins 0.2.
> 

Hi Lluis, very interesting release!

With which license is covered this library? It would be interesting to 
specify this on the info page.

Thanks in advance,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Is the Search working in the mono-project wiki?

2007-05-14 Thread Andrés G. Aragoneses [ knocte ]
John Anderson escribió:
> There is also a google search available that works pretty well, but it 
> would be nice to have the built in search work too.

Yes. And at least, if we know that the built-in search doesn't work, a 
better situation is to disable it instead of exposing something buggy.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Is the Search working in the mono-project wiki?

2007-05-14 Thread Andrés G. Aragoneses [ knocte ]
I am realising that the Search functionality is not working at all. For 
example, the following page contains the word "RSS":

http://www.mono-project.com/SVN

However, if you search for the RSS word, no results:

http://www.mono-project.com/Special:Search?search=RSS&go=Search


I think that fixing this is important. Many people look for docs with 
this option.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] {Readkey} Error CS0117 System.Console does not contin definition

2007-04-10 Thread Andrés G. Aragoneses [ knocte ]
Charles Black escribió:
> Hi everyone, i recently installed Mono(0.13) in Kubuntu and im starting to
> work on it but i get an error messages saying:
> 
> 'System.Console' does not contain a definition for 'ReadKey'(CS0117).
> 
> I guess im missing something or something happened during installation,
> thanx in advance.

That version of Mono is ancient.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] "Empty catch" rule proposal for Gendarme?

2007-03-28 Thread Andrés G. Aragoneses [ knocte ]
Hello. I'm just a little upset of the many times I have to spend debug 
sessions because of empty catch blocks (swallowing any exception that 
the programmer never could imagine...). Then I was just wondering if it 
was worth to create a rule for Gendarme that warned about it:

catch
{
}

OR:

catch(Exception)
{
}

OR:

catch(Exception ex)
{
}

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] [MonoDevelop] ANNOUNCE: Mono.Addins 0.1

2007-03-28 Thread Andrés G. Aragoneses [ knocte ]
Matthijs ter Woord escribió:
>  From this message i understand that your mini-framework just loads the 
> complete application inside one appdomain (the second one)?
> 
> If so, it's technically just restarting the application then when taking down 
> that appdomain.

I suppose so. The purpose of this strange technique is that you cannot 
use ShadowCopy==true in your first domain. AFAIK this flag can only be 
set for new dinamically created AppDomains in 1.1 and 2.0 profile. 
However my mini-framework does not close the first domain when launching 
the seconds, it just lays it there sleeping...

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] [MonoDevelop] ANNOUNCE: Mono.Addins 0.1

2007-03-28 Thread Andrés G. Aragoneses [ knocte ]
Lluis Sanchez escribió:
>>> However, as Matthijs pointed out in his reply, app-domains don't play
>>> well with GUI toolkits, and GTK# is not an exception.
>> M, why? I didn't have any information about this. Could you 
>> ellaborate? It sounds very strange to me because I already have a 
>> mini-framework which supports this and uses WinForms.
> 
> I can't tell for WinForms, but it won't work with gtk#. One problem is
> that the GType types that gtk# creates for every managed subclass of a
> widget are per-process, not per-assembly, and you'll get errors when
> trying to use the same classes from different app-domains. Another
> problem is that gtk# does not support having two managed objects to
> represent the same GTK object. What would happen if you override the
> OnKeyPress event on both objects? which one would be called? And even if
> you application had an strict control on the objects and avoided
> creating two managed objects for the same GTK object, the application
> has no control on the main GTK thread, so for example the GTK thread
> might receive an event for an object from domain A, while running in
> domain B.

Very interesting Lluis. However, I think that these problems shouldn't 
arise for this feature because it wouldn't imply using objects across 
appDomains. As I understand it (and as I have coded my mini-framework), 
the only usage of AppDomain boundaries crossing would be at the 
application launch, where the launcher would "launch" the core of the 
addin manager (and subsequently the addins...) in a second appdomain 
configured with ShadowCopy==true. Since that launch, no other 
inter-AppDomain calls would be launched. The main program flow would 
live and die in the second appdomain as if it were the main appdomain.


> GTK# can probably be improved to support multiple domains (even with
> some limitations), but it would require an important redesign of the
> internals (e.g. reference tracking), and IMO the effort needed is not
> worth it.

Well, perhaps in a far future we could have a completeley managed GTK# 
library. That would solve the problem too I guess :)

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ANNOUNCE: Mono.Addins 0.1

2007-03-27 Thread Andrés G. Aragoneses [ knocte ]
Lluis Sanchez escribió:
>>> I'm pleased to announce the release of Mono.Addins.
>>>
>>> Mono.Addins is a generic framework for creating extensible applications,
>>> and for creating libraries which extend those applications.
>>> [...]
>> Hi Lluis, does it support the reload of an addin, if its assembly is 
>> updated, without restarting the whole application?
>>
>> If yes, is it based on ShadowCopy AppDomain launching so as to allow 
>> overwritting the assemblies in Win32 OS?
>>
>> If not, I would probably be interested in adding this feature in it for 
>> using it in my projects. What do you think?
> 
> Dynamic updating of add-ins is not supported right now, but I'm pretty
> sure it will be supported in the future, taking into account the
> feedback I got about that.

Thanks for the information. I will see if I can help in adding it or 
else I'll wait for it.


> However, as Matthijs pointed out in his reply, app-domains don't play
> well with GUI toolkits, and GTK# is not an exception.

M, why? I didn't have any information about this. Could you 
ellaborate? It sounds very strange to me because I already have a 
mini-framework which supports this and uses WinForms.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ANNOUNCE: Mono.Addins 0.1

2007-03-27 Thread Andrés G. Aragoneses [ knocte ]
Lluis Sanchez escribió:
> Hi,
> 
> I'm pleased to announce the release of Mono.Addins.
> 
> Mono.Addins is a generic framework for creating extensible applications,
> and for creating libraries which extend those applications.
> [...]

Hi Lluis, does it support the reload of an addin, if its assembly is 
updated, without restarting the whole application?

If yes, is it based on ShadowCopy AppDomain launching so as to allow 
overwritting the assemblies in Win32 OS?

If not, I would probably be interested in adding this feature in it for 
using it in my projects. What do you think?

Thanks in advance.

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Proposal: Monodevelop month of hacking

2007-02-11 Thread Andrés G. Aragoneses [ knocte ]
C. Bergström escribió:
> [...]
> I'm not sure how many Mac Mono hackers there are, but in the short bit 
> of time I spent on irc. I did see a number of them complain about the 
> required dependencies and also that it was pretty unstable.. How many 
> hidden Mono Mac users are really out there..?

As well as Mac hackers, I'm sure MonoDevelop would get much many users
and contributors if in next release the Mono Project releases installers
for Win32. Some people, like my case, have no choice for the moment and
must use Windows at work, so using & contributing MonoDevelop applies
only to spare time.

Just my 2 cents ;)

Regards,

Andrés  [ knocte ]

-- 


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] web services (soap) doesn't work too well when using SSL?

2007-02-07 Thread Andrés G. Aragoneses [ knocte ]
Rune Elvemo escribió:
> (...)
> 
> Btw: I'm using Mono v 1.1.17.1 (from latest ubuntu)


Webservices has been improved considerably in the latest releases so I 
would recommend you to upgrade (to 1.2.2.1 or 1.2.3) and test again.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] compiling VS2005 project in mono

2007-02-05 Thread Andrés G. Aragoneses [ knocte ]
Miguel de Icaza escribió:
>>> I need to compile Visual C# Express 2005 project in MONO in Windows but 
>>> prj2make does not support 
>>> VS2005 projects.
>> You're wrong; prj2make has been hacked recently to add that support. If
>> you use the SVN version of MonoDevelop you should be able to open your
>> project with it.
> 
> The command line tool `prj2make' has not been updated or modified and is
> unable to open VS2005 solutions.


BTW, this page is wrong then:
http://www.mono-project.com/Command-Line_Tools#Project_converstion_.26_deployment

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Need your help: Mainsoft/Novell "Race to Linux"

2007-02-05 Thread Andrés G. Aragoneses [ knocte ]
Miguel de Icaza escribió:
> Mainsoft and Novell are organizing an event to port applications
> from Windows to Linux using Mono or Grasshopper.
> 
> And we are looking for good candidates to port: we need some
> interesting, .NET-based open source applications that would be
> interesting to port to Linux.
> 
> If you have some suggestions of what could be a good challenge for
> an ASP.NET, Winforms or server app to port, please email me your
> suggestions.


My suggestion:

http://forum.castleproject.org/viewtopic.php?t=230


There, you can see that a developer has ported the popular "Pet Shop" 
proof of concept to ASP.NET using the CastleProject framework (MonoRail, 
a Ruby on Rails port to .NET).

It could be wonderful to have this working on Mono too.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mod_mono directoy path issues.

2007-01-29 Thread Andrés G. Aragoneses [ knocte ]
Jim Canfield escribió:
>>> Example path would look like this:  \\webserver\DATA\Some directory with 
>>> spaces\File with Space and paren(1).pdf
>>> 
>> That URI is platform specific, as it is the way SMB URIs are specified
>> in the MS platform. I would think that the cross-platform equivalent
>> would be something like "smb://webserver/DATA/..." but I bet you will
>> have more issues beyond that (because accessing those from most linux
>> desktops results in a slower access and read-only; and because you're
>> probably resolving names through WINS instead of DNS).
>>   
> Apologies: The path is not a UNC URI, rather it's a full http://path. 
> My example path above is misleading.

Then I guess it's a bug in Mono, so please file a bug along with the
smallest testcase possible:

http://www.mono-project.com/Bugs

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mod_mono directoy path issues.

2007-01-29 Thread Andrés G. Aragoneses [ knocte ]
Jim Canfield escribió:
> Greetings,
> 
> I recently inherited a small ASP web app which I'm trying to make work 
> on a mod_mono linux server. I have it working about 90%, however, I'm 
> having trouble with file paths that contain spaces and parenthesis .  
> I'm wondering how I might fix this? 
> 
> Here is the code that calls and displays the file path:
> 
> //Get the file path
> string path = new DataManager().GetSingleValueAsString(SQL);
> this.EmbeddedFile.Text = " NAME='DocumentFrame' SRC='DATA" + path + "'>";
> 
> 
> Example path would look like this:  \\webserver\DATA\Some directory with 
> spaces\File with Space and paren(1).pdf


That URI is platform specific, as it is the way SMB URIs are specified
in the MS platform. I would think that the cross-platform equivalent
would be something like "smb://webserver/DATA/..." but I bet you will
have more issues beyond that (because accessing those from most linux
desktops results in a slower access and read-only; and because you're
probably resolving names through WINS instead of DNS).

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] CMS on .Net/Mono -> Open Source

2007-01-28 Thread Andrés G. Aragoneses [ knocte ]
Jonathan Pryor escribió:
> You want to ensure that changes to your code are still accessible to
> you, regardless of who makes the changes --> GPL. Examples: Linux, most
> applications.

Sorry to jump in but I'm not sure if this last statement is totally
correct. I'll demonstrate it with an example:

- Programmer A releases program X under the GPL.
- Vendor A asks some programmer B to change program X for a business need.
- Programmer B makes modifications to program X and calls it program Y,
giving it a GPL license (as it is mandatory for him), and then gives
program Y (along with its sources, as it is mandatory by the use of the
GPL) to Vendor A, without releasing it to the public (although he could
do it if he wanted).

Result: there have been modifications that have not reached programmer A.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] compiling VS2005 project in mono

2007-01-26 Thread Andrés G. Aragoneses [ knocte ]
Miguel de Icaza escribió:
>> Andrus escribió:
>>> I need to compile Visual C# Express 2005 project in MONO in Windows but 
>>> prj2make does not support 
>>> VS2005 projects.
>> You're wrong; prj2make has been hacked recently to add that support. If
>> you use the SVN version of MonoDevelop you should be able to open your
>> project with it.
> 
> The command line tool `prj2make' has not been updated or modified and is
> unable to open VS2005 solutions.
> 
> You must use MonoDevelop for that

Oh ok, I though the MonoDevelop AddIn was a binding.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] compiling VS2005 project in mono

2007-01-26 Thread Andrés G. Aragoneses [ knocte ]
Andrus escribió:
> I need to compile Visual C# Express 2005 project in MONO in Windows but 
> prj2make does not support 
> VS2005 projects.

You're wrong; prj2make has been hacked recently to add that support. If
you use the SVN version of MonoDevelop you should be able to open your
project with it.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Gnome in C# and Mono, What do you think?

2007-01-22 Thread Andrés G. Aragoneses [ knocte ]
Carlos Adriano Portes escribió:
> In my opinion Gnome should be developed using mono and c#, it is
> standard and would help gnome to improve very much, kde is develop
> mainly in C++ and it is productive because it ts based in one
> language, if gnome was developed using one language (and a productive
> one) it would give the oportunity to improve gnome in many ways:
> 
> 1-More programers would join the developers team.
> 2-Gnome applications would be developed faster than usual.
> 3-The quality and number of gnome applications would grow.
> 4-Would eliminate the gap between Gnome and Kde (being a Gnome user
> does not mean that Gnome is better/worse than kde) in some cases.
> 5-Some other that you friends could imagine...


Nice thoughts. But there are many people who think the opposite so I 
guess the ideal way would be to create a parallel project. A proposal in 
this way was already proposed some time ago here:

http://necudeco.blogsome.com/2006/05/19/mono-desktop-enviroment/


Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Nullable types in web services

2007-01-18 Thread Andrés G. Aragoneses [ knocte ]
Atsushi Eno escribió:
> No, so you can file it.

http://bugzilla.ximian.com/show_bug.cgi?id=80551

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Nullable types in web services

2007-01-18 Thread Andrés G. Aragoneses [ knocte ]
Atsushi Eno escribió:
> You are too quick to get excited. Actually my guess (that was with
> buggy CodeDom) that my System.Xml fix would fix this specific WSDL
> issue was not correct. It is not fixed and no idea when it will be
> fixed.

Have any of you created a bug in bxc? It would be nice to track the
progress of this bug because I think I will depend on it in the near future.

Thanks,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Recursive XML serialization? XML serialization of cyclic objects?

2007-01-13 Thread Andrés G. Aragoneses [ knocte ]
Rodolfo Campero escribió:
>> implement custom serialization for each of my classes. In fact, what I
>> want to be able to do is to XMLserialize my cyclic objects without
>> writing more code.
> 
> If the only thing you need is to serialize cyclic objects to XML, [...]

Thanks Rodolfo! I will take a look at the links.

Regards,

Andrés  [ knocte ]

-- 


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Recursive XML serialization? XML serialization of cyclic objects?

2007-01-13 Thread Andrés G. Aragoneses [ knocte ]
Atsushi Eno escribió:
>> Do you mean that current SVN is broken in this scenario, or that you
>> don't like the API?
> 
> I mean, the behavior (almost equal to the API).
> 
> Try to serialize a class which contains members which is ISerializable.
> The serialization is then not contract based anymore.

But, would this affect me if I don't use ISerializable interface in my 
classes?? I ask this because my desire would be to have no need to 
implement custom serialization for each of my classes. In fact, what I 
want to be able to do is to XMLserialize my cyclic objects without 
writing more code.

BTW, ISerializable AFAIK is for binary serialization, not XML. Does it 
then have any influence in the case we are discussing?

Thanks,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Recursive XML serialization? XML serialization of cyclic objects?

2007-01-13 Thread Andrés G. Aragoneses [ knocte ]
Atsushi Eno escribió:
>> Do you mean that current SVN is broken in this scenario, or that you
>> don't like the API?
> 
> I mean, the behavior (almost equal to the API).
> 
> Try to serialize a class which contains members which is ISerializable.
> The serialization is then not contract based anymore.

But, would this affect me if I don't use ISerializable interface in my 
classes?? I ask this because my desire would be to have no need to 
implement custom serialization for each of my classes. In fact, what I 
want to be able to do is to XMLserialize my cyclic objects without 
writing more code.

BTW, ISerializable AFAIK is for binary serialization, not XML. Does it 
then have any influence in the case we are discussing?

Thanks,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Recursive XML serialization? XML serialization of cyclic objects?

2007-01-12 Thread Andrés G. Aragoneses [ knocte ]
Thanks for your answer Atsushi.

Atsushi Eno escribió:
> It is possibly only with NetDataContractSerializer and cannot be
> done with DataContractSerializer. Since NetDataContractSerializer
> sucks in general (there is no point of using it instead of runtime
> serialization), the priority is low at my hands.

It's ok, I was supposing not to expect it in the short/medium term.


> Indigo's "design
> by contract" concept is becomes almost implicit (== practically
> broken) when ISerializable objects are involved.

Do you mean that current SVN is broken in this scenario, or that you
don't like the API?


> Probably you could try runtime serialization with Soap formatter:
> System.Runtime.Serialization.Formatters.Soap

Will look into it! Thanks.

Andrés  [ knocte ]

-- 


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Recursive XML serialization? XML serialization of cyclic objects?

2007-01-12 Thread Andrés G. Aragoneses [ knocte ]
Robert Jordan escribió:
>> How can I send "myObject" via XML webservice for consumption? I am aware
>> that this is not possible to be XML-serialized with .NET1.1 but, can I
>> do it with 2.0 or Indigo?
> 
> I'm not aware of any Web Service standard allowing that
> kind of cycles.

Indigo (WCF) seems to support it! :

http://groups.google.com/group/microsoft.public.dotnet.languages.csharp/browse_thread/thread/4e76b309c00eaf49/9235fd20edc55d7f#hdropenedd02799e0c3b43525

I will then be eager for olive to be released :D

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Recursive XML serialization? XML serialization of cyclic objects?

2007-01-12 Thread Andrés G. Aragoneses [ knocte ]
Andrés G. Aragoneses [ knocte ] escribió:
> In case you are interested, I wrote a blog post about it (it's based on 
> NHibernate mapping framework; oh! and sorry, it's written in Spanish but 
> perhaps you can more or less understand it using the automatic 
> translation service link I have at the top of the page).

Forgot the link: 
http://knocte.blogspot.com/2006/12/serializacin-binaria-con-nhibernate.html

Regards,

Andrés  [ knocte ]

-- 


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Recursive XML serialization? XML serialization of cyclic objects?

2007-01-12 Thread Andrés G. Aragoneses [ knocte ]
Hi Robert, thanks for your answer!

Robert Jordan escribió:
> Andrés G. Aragoneses [ knocte ] wrote:
>> Having this kind of object:
>>
>>  class classA
>>  {
>>  int x;
>>  classA z;
>>
>>  public int X
>>  {
>>  get { return this.x; }
>>  set { this.x = value; }
>>  }
>>
>>  public classA Z
>>  {
>>  get { return this.z; }
>>  set { this.z = value; }
>>  }
>>
>>  }
>>
>>  static class Program
>>  {
>>  static void Main(string[] args)
>>  {
>>  classA myObject = new classA();
>>  myObject.X = 2;
>>  myObject.Z = myObject;
>>  }
>>  }
>>
>>
>> How can I send "myObject" via XML webservice for consumption? I am aware
>> that this is not possible to be XML-serialized with .NET1.1 but, can I
>> do it with 2.0 or Indigo?
> 
> I'm not aware of any Web Service standard allowing that
> kind of cycles.

Neither if I create my custom XmlSerializer? How can I tell my ASP.NET 
webservice to use it instead of the default one?


> If you really need such complex classes and you don't

Well, it's not that complex to have a domain model that allows it. For 
example, a very common scenario:

public class Parameter {
   public Client Parent;
   public int Value;
}

public class Client {
   public List Parameters;
}

Parameter parameter = new Parameter();
Client client = new Client();
parameter.Parent = client;
parameter.Value = 3;
client.Parameters = new List();
client.Parameters.Add(parameter);


The 'client' object then is an example of what can be retrieved from an 
Object-Relational Mapping Framework. It has a list that represents the 
1-N relation, and the parameter has a reference to the parent object 
(N-1 relation).


> care about interop, you could switch to XSP/ASP.NET-hosted
> .NET Remoting using a HttpChannel. This would require to design
> the classes [Serializable], which is an issue of its own, though.

Yes, this is the temporary workaround we are using: binary 
serialization. But this is kind of hackish and also I think that in the 
future we will need to parse the objects via XSLT; that's why I'm 
interested in XML serialization.


> Anyway, my strong opinion is: *never* employ remoting or Web Services
> w/out a remoting facade pattern that maps between complex objects
> and simple (remotable) objects.

Well, I think I understand your concern about this. However I think we 
were using this pattern until we realised we had to write many code for 
each class of the domain model so as to write these translation 
mechanisms. Then we opted for a totally transparent solution that, 
however, needs a reflection-based conversion so as to mark some parts of 
the objects as "lazy" (not retrieved) and be able to serialize them.

In case you are interested, I wrote a blog post about it (it's based on 
NHibernate mapping framework; oh! and sorry, it's written in Spanish but 
perhaps you can more or less understand it using the automatic 
translation service link I have at the top of the page).

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Recursive XML serialization? XML serialization of cyclic objects?

2007-01-11 Thread Andrés G. Aragoneses [ knocte ]
Having this kind of object:

 class classA
 {
 int x;
 classA z;

 public int X
 {
 get { return this.x; }
 set { this.x = value; }
 }

 public classA Z
 {
 get { return this.z; }
 set { this.z = value; }
 }

 }

 static class Program
 {
 static void Main(string[] args)
 {
 classA myObject = new classA();
 myObject.X = 2;
 myObject.Z = myObject;
 }
 }


How can I send "myObject" via XML webservice for consumption? I am aware
that this is not possible to be XML-serialized with .NET1.1 but, can I
do it with 2.0 or Indigo?

Thanks in advance,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] C# command line parsing library

2007-01-04 Thread Andrés G. Aragoneses [ knocte ]
Chris Seaton escribió:
> Is there a library for parsing command lines in C#? Or do any C#  
> applications have a reusable class for parsing command lines. I'm  
> looking for something where you specify flags and default values and  
> things and gets values from the command line. Like gopt or something.

I think the most standard way to do this is the library 
"Mono.GetOptions" (search in google).

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Native support for VS2005 Projects in Monodevelop

2006-12-21 Thread Andrés G. Aragoneses [ knocte ]
Ankit Jain escribió:
> What error did you get?

Yesterday I got a very long error inside a huge error dialog. However
with today's last checkins to MonoDevelop now I get this error:

/home/knocte/(...)/mcs/nunit20/nunit.sln(3): Unsupported or unrecognized
project: 'samples\jsharp\jsharp.vjsproj'. See logs.
/home/knocte/(...)/mcs/nunit20/nunit.sln(7): Unsupported or unrecognized
project : 'samples\cpp-sample\cpp-sample.vcproj'. See logs.
/home/knocte/(...)/mcs/nunit20/nunit.sln(11): Unsupported or
unrecognized project: 'install\install.vdproj'. See logs.

I suppose that this .sln file contains project types not supported by
MonoDevelop (by now, and never I suppose), so a nice workaround to allow
to work with a solution like this would be this feature:

http://bugzilla.ximian.com/show_bug.cgi?id=77723

Regards,

Andrés  [ knocte ]


BTW: I am seeing that the project I wanted to open, when built with
NAnt, a "build\bin" is created, instead of creating a "build +
Path.DirectorySeparatorChar + bin", so this is not cross-platform.
-- 


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] CursesSharp crossplatform example release

2006-12-21 Thread Andrés G. Aragoneses [ knocte ]
Florian Hester escribió:
> Then its now under the LGPL.

Florian, the license to choose is up to you. Perhaps you're not 
interested in seeing propietary apps that use youre library freely, and 
then you would be more interested in a dual license (as MySQL or DB4O 
are doing).

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Native support for VS2005 Projects in Monodevelop

2006-12-20 Thread Andrés G. Aragoneses [ knocte ]
Ankit Jain escribió:
> This is a call for testing :)
> 
> Code for providing native support for vs2005 solutions/projects is in
> svn now, in the prj2make-sharp-lib. Native support means that you can
> directly open vs2005 projects in monodevelop. Any changes made to the
> project through monodevelop would get reflected in the project
> file. So you can effectively share the same project files between VS2005 and
> MonoDevelop.
> 
> If you try to add a monodevelop solution/project (.mds/.mdp) to a
> vs2005 solution,
> then it will be converted to the vs2k5 equivalent files (solution
> folders/csproj etc).
> 
> The addin tries to do non-destructive writes of the sln/project files,
> i.e., it will (try) not
> to delete things that it doesn't understand.
> 
> It hasn't really seen much testing besides by that done by myself.
> You'll need monodevelop from SVN for
> trying this out. Its not complete yet, but seems to be working fine for most
> cases (that i tried :). Would be nice if we can see what doesn't work or what
> else is required to be supported in this.


Ankit, thanks very much for this great work. I have been trying it a bit
and worked fine. However today I tried to open the following sln file
and I got an error:

http://svn.myrealbox.com/source/trunk/mcs/nunit20/nunit20.sln

Should I file a bug about it?

Regards,

Andrés  [ knocte ]

-- 


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Deveel Regex 1.0

2006-12-19 Thread Andrés G. Aragoneses [ knocte ]
Antonello Provenzano escribió:
> Dear Mono Folks,
> 
> I just released the version 1.0 of Deveel Regex, a library for
> compiling and manage regular expressions strings, under the LGPL
> license.
> It has been inspired by GNU Regex project by Wes Biggs either if you
> will find many differences from the original one, due to the different
> environments they were built on.
> It's major additional features to the System.Text.RegularExpressions
> built in regex processor of the Mono framework are the following:
> 
> * Speeding up the performances for the compilation and iteration
> through multiple matches
> * Multiple syntaxes supported, from POSIX to Perl4, Perl5, etc.
> 
> You can find it at the address: http://sourceforge.net/projects/deveel-regex
> 
> I hope you will find it useful.

Hello. This seems to be very interesting.

Just a simple suggestion: add another kind of syntax, a readable and 
statically typed syntax: 
http://flimflan.com/blog/ReadableRegularExpressions.aspx

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Jakarta Struts for .net/mono

2006-12-15 Thread Andrés G. Aragoneses [ knocte ]
Alexander escribió:
> I writing port of Jakarta Struts 1.3
> Instead of asp.net WebForms it will provide ViewEngines (like MonoRail)
> and at this time just simple IronPython based engine available.
> 
> Ports already available:
> * commons-chain (Chain Of Responsibility pattern for the request processor)
> * commons-validator (for client data validation)
> * commons-beanutils (to populate actionForms)
> * Implemented base functionality:
> chain for request processing, actionForms, actions, plugins support,
> custom security mechanism (with simple xml file based storage),
> configuration (so clise to original)
> 
> In progress:
> * ValidatorForm and dependencies (MessageResources, 
> MessageResourceFactory, etc.)
> * Sample Web application
> 
> Please give me a piece of good advice about design:
> Unfortunately ASP.NET provides sealed HttpContext, HttpRequest, HttpResponse
> which cannot be used to write mocks for testing (I love javax.servlet).
> I considering to wrap this objects to complete Java Servlet API and use 
> this interfaces
> for whole port implementation (except httphandler which will instantiate 
> wrapped objects)
> and make port completely independent from System.Web.
> At this time I wrap HttpContext, HttpRequest, HttpResponse into custom
> classes which so close to original.
> If it sounds wild, it's possible to use asp.net HttpContext, etc..,
> but unfortunately it's a farewell to unit testing.
> 
> If somebody interested, please help with this dilemma and project name :).
> Current name is "Nemo", but my offer is "Boast" as Struts synonym.

Hey, this sounds wonderful.

Just my two cents: why not "NStruts" (so as to follow the Java->.NET 
common port practices ;) ?

And I would love to try out your framework if you implement a ViewEngine 
based on XmlSerialization of the Controller, with XSLT transformation 
for the view (XML to XHTML with XSLT). This is the kind of methodology I 
have been using recently with Maverick.NET (which BTW is a port of the 
Java-based Maverick project), instead of using ASP.NET or (IMHO)strange 
template engines (such as NVelocity).

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] First try at MoMA

2006-11-27 Thread Andrés G. Aragoneses [ knocte ]
Andrés G. Aragoneses [ knocte ] escribió:
>  >EndPoint Socket.get_RemoteEndPoint()
>  >void WebRequest.set_Credentials(ICredentials)
>  >WebResponse WebRequest.GetResponse()
>  >void WebRequest.set_Proxy(IWebProxy)
> 
> This three seemed too common to throw NotImplementedException, am I right?

s/three/four

> And finally, one that should be nice to (at least) commit a stub for:

Oops, I wanted to write:

RemoteConfiguration.Configure(string, bool)

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] First try at MoMA

2006-11-27 Thread Andrés G. Aragoneses [ knocte ]
Hello,

I have been trying this wonderful application and I have come out with 
some very strange warnings at scanning some free software projects (like 
log4net or NHibernate):

 >Type Exception.GetType(): method not yet in Mono

This is very strange, because it seems a very basic Method.


 >CompilerResults 
CodeDomProvider.CompileAssemblyFromSource(CompilerParameters, String[])

I have noticed that recently there have been many commits as SVN 
completing the CodeDomProvider namespace. Is normal that this method is 
not implemented yet?


 >EndPoint Socket.get_RemoteEndPoint()
 >void WebRequest.set_Credentials(ICredentials)
 >WebResponse WebRequest.GetResponse()
 >void WebRequest.set_Proxy(IWebProxy)

This three seemed too common to throw NotImplementedException, am I right?

Besides these ones, I have noticed that Log4Net uses some appenders that 
are platform specific: ColoredConsoleAppender (kernel32.dll), 
LocalSysLogAppender (libc), NetSendAppender(netapi32.dll). Ok with that, 
but these others seem not platform specific (because they are at Util 
namespace) though they depend on Kernel32.dll:

 >Class log4net.Appender.OutputDebugStringAppender:
 >void Append(LoggingEvent) void OutputDebugString(string)  >Kernel32.dll
 >Class log4net.Util.NativeError:
 >string GetErrorMessage(int)   int FormatMessage(int, IntPtr&, int, >int, 
String&, int, IntPtr)   Kernel32.dll

Is it normal?


After that, inspecting some projects of mine that use WinForms and 
WebServices:

 >void TabPage.set_Location(Point)
 >Object SettingsBase.get_Item(string)
 >void XmlSerializationWriter.WriteStartElement(string, string, Object, 
bool, XmlSerializerNamespaces)
 >int XmlSerializationReader.get_ReaderCount()
 >void XmlSerializationReader.CheckReaderCount(Int32&, Int32&)
 >void HttpWebClientProtocol.CancelAsync(Object)


And finally, one that should be nice to (at least) commit a stub for:
 >Object SettingsBase.get_Item(string)


Thanks for any guidance.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] SharpOS.org

2006-10-31 Thread Andrés G. Aragoneses [ knocte ]
Michael Schurter escribió:
> Since the idea of a managed operating system has been discussed at 
> length on the mono-devel-list, I went ahead and registered sharpos.org!
> 
> I encourage anyone interested in developing a managed operating system 
> to visit http://sharpos.org
> 
> Please start editing the wiki and sign up for the mailing list[1] to 
> continue this discussion.  That way we can stop flooding Mono lists with 
> OT posts!
> 
> (Someone is welcome to register a SourceForge.net project as well.  We 
> can always move to SF.net when that project becomes available or split 
> services between the two sites.)
> 
> [1] http://lists.sharpos.org/listinfo.cgi/sharpos-devel-list-sharpos.org
> 

This idea is fantastic.

I would propose the following:

- Use NovellForge instead of SourceForge.net (the UI is much simpler and 
fast, and it supports bugzilla, much wonderful than the issue tracker of 
SF.net).
- Create a gmane group that hosts the list (I can do this, just approve 
the idea please).

Regards,

Andrés  [ knocte ]

-- 


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Learning ASP.NET?

2006-10-30 Thread Andrés G. Aragoneses [ knocte ]
Carlos Adriano Portes escribió:
> I would like to know where I could get some material for me to learn
> ASP.NET, I am learning C# in order to be able to build applications
> with only the compiler and a editor, so I would like to learn ASP.NET
> to use with my linux as well!
> I know HTML and think that ASP.NET tags are not so difficult to
> understand, can someone point me a direction to follow?

IMHO if you want to do web development with Mono you should try 
MonoRail[1]. It's a port of RoR (Ruby on Rails) to C# and works very 
well. In fact, many people think that the WebForms methodology of 
ASP.NET is flawed[2][3], and learning the MVC model of MonoRail is quite 
better.

Regards,

Andrés  [ knocte ]

-- 
[1] http://www.castleproject.org/index.php/MonoRail
[2] http://hammett.castleproject.org/?p=59
[3] http://www.ayende.com/Blog/MonoRailVsASPNet.aspx

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] C# and Aspect Oriented Programing

2006-10-01 Thread Andrés G. Aragoneses [ knocte ]
Milosz Tanski escribió:
> Does anyone know of any Aspect Oriented frameworks that work with mono?
> I've looked at AspectSharp from Castle Rock, but according to them it
> doesn't work with mono? At my school one the interesting on-going
> projects is a AOP project... So far the people i talked to told me to
> use AspectJ. I'm not a Java guy, nor ever was I, so I'm looking for a
> solution that works with C#/mono so I'm not forced to use Java/Eclipse.

I think Spring.NET implements AOP[1], but don't know if anyone has 
already tested it with Mono.

Regards,

Andrés  [ knocte ]

[1] http://www.springframework.net/doc/reference/html/aop.html
-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mono crash on latest SUSE 10.1 install

2006-09-29 Thread Andrés G. Aragoneses [ knocte ]
Ben Clewett escribió:
> in (wrapper managed-to-native) System.Drawing.GDIPlus:GdipDisposeImage 
> (intptr) <0x4>
> in (wrapper managed-to-native) System.Drawing.GDIPlus:GdipDisposeImage 
> (intptr) <0xffd8>
> in System.Drawing.Image:DisposeResources () <0x10>
> in System.Drawing.Image:Dispose (bool) <0x13>
> in System.Drawing.Image:Finalize () <0x10>
> in (wrapper runtime-invoke) System.Object:runtime_invoke_void 
> (object,intptr,intptr,intptr) <0x51c57456>
> 

I have had similiar exception for disposal of images in Mono 1.1.17, and 
some bugs about ImageLists on MWF have been fixed so I suppose it will 
be fixed for the next release.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] problem launching a self compiled application

2006-09-28 Thread Andrés G. Aragoneses [ knocte ]
Norbert escribió:
> as normal user I can compile my application without
> any errors. It uses Windows.Forms for graphical
> output. But  I cannot launch it:
> mono test1.exe
> fails and reports the errors which you can find at the
> end of this message. As root I can launch the program
> normally and it works fine. The system I use is Debian
> Sarge and Mono 1.1.17.1 (installed by binary
> installer).

The problem seems to be that a DLL file is not found. If being root 
finds it and not as a user, perhaps you need to stablish some 
environment variables that the superuser already has, so as to let mono 
find the libgdiplus library.  I don't remember them but you should be 
able to find info about it looking at the archives or the mono-project wiki.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Garbage-collecting a remoting singleton object in a service?

2006-09-04 Thread Andrés G. Aragoneses [ knocte ]
Thanks for your answer Robert!

> That's not the real reason why they are GCed. If an object
> is casted to one of its interface it still remains the
> same object.
> 
> If the client is implementing IClient while subclassing
> MarshalByRefObject, the usual remoting lifetime constraints
> will take effect.
> 
> You can control the lifetime (on the client) by overriding
> InitializeLifetimeServices.

I see. But I am using also a null value for the return value of 
InitializeLifetimeService in the client, because I want the client to 
keep connected until normal program termination (or CTRL-C hitted by the 
user at the client machine), which will actually garbage collect the 
whole process.

Snippet:

class Client : MarshalByRefObject, IClient
{
   public override object InitializeLifetimeService()
   {
 return null;
   }

   /* methods of IClient interface... */
}


> The IClient proxy (on the server) is subject to be GCed after
> it's removed from the hClients dictionary

That's the thing I was unsure about, thanks for pointing out!

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Garbage-collecting a remoting singleton object in a service?

2006-09-04 Thread Andrés G. Aragoneses [ knocte ]
Robert Jordan escribió:
>> I am interested in implementing a service (windows service in windows, 
>> and using mono-service on linux, I suppose) that hosts a singleton 
>> remoting object. As I have read on some docs, no leasing management is 
>> needed if no SAO/CAO hosting method is used (returning null in 
>> InitializeLifeTimeService method, as I will use a Singleton instance) 
>> but, how can I garbage-collect manually this server object on the 
>> OnStop() method of the service (so as to create a new instance again on 
>> the OnStart method)?
> 
> To achieve this, you have to register the singleton object manually.
> 
> Throw away the  entry from you server's remoting config
> and use this code instead (in server's code, of course):
> 
> 
> YourServerClass singleton;
> 
> OnStart ()
> {
>   singleton = new YourServerClass ();
>   RemotingServices.Marshal (singleton, objectUri);
> }
> 
> OnStop ()
> {
>   RemotingServices.Disconnect (singleton);
>   // do what you called "garbage-collect manually".
> }
> 
> 
> where "objectUri" is the objectUri-attribute you previously
> used in server's remoting config.


Thanks for the answers Robert and Lluis. I was using the Disconnect 
method but I was unsure if it was the thing I needed; in fact, it's a 
bit strange that the "opposite" of Disconnect is Marshal, instead of 
Connect, which I think is the method used by the other side (the 
clients) if they don't use the Activator.GetObject() form.

BTW, I am supposing that the garbage-collection of the client objects is 
automatic because I store them as IClient objects, not as 
MarshalByRefObject, am I right?

I mean, when a client logs into my server, I store it's reference with:

class Server : MarshalByRefObject , IServer {

   private object oLock = new object();
   private IDictionary hClients =
 new Dictionary();

   public void Login(IClient oClient){
 lock(this.oLock){
   this.hClients.Add(oClient.Guid, oClient);
 }
   }

}


When the client disconnects, I remove the reference to the object with:

   public void Logout(IClient oClient){
 lock(this.oLock){
   if (this.hTerminal.ContainsKey(oClient.Guid)){
 this.hTerminal.Remove(oClient.Guid);
   }
 }
   }

Is this garbage-collecting them too?

Thanks again.

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Garbage-collecting a remoting singleton object in aservice?

2006-09-04 Thread Andrés G. Aragoneses [ knocte ]
Carlos Ble escribió:
> Hi,
> 
> El vie, 01-09-2006 a las 14:53 +0100, Bradley, Peter escribió:
>> Just a query...
>>
>> Why do you need to use a singleton object?  We've always used SingleCall 
>> objects, and these die after each call.  I take it you're talking about a 
>> SAO, as the term "singleton" is usually used to refer to an SAO.  We've 
>> never found a justification for using a singleton object.
>>
> 
> And what happend when you want to have (in server side) a shared struct
> or shared hash hosted in memory for all calls?. For example to keep an
> array of client sessions at the server. Do you prefer a SingleCall
> object with static variables instead of singleton object?

Thanks for the intervention Carlos :)

Indeed, I was going to reply with a similar explanation. Perhaps Peter 
Bradley has never had the need to use a Singleton type object because 
all of his remoting methods are stateless, so in his case the 
implementation could be converted into webservices I guess.

In my case I need to save a state between calls. In fact, I need a 
similar scenario than the one explained by Carlos: some clients, when 
invoking the server methods, need to contact other client already 
connected and send them parameters.

I hope this has clarified your doubts ;)

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Garbage-collecting a remoting singleton object in a service?

2006-09-01 Thread Andrés G. Aragoneses [ knocte ]
I am interested in implementing a service (windows service in windows, 
and using mono-service on linux, I suppose) that hosts a singleton 
remoting object. As I have read on some docs, no leasing management is 
needed if no SAO/CAO hosting method is used (returning null in 
InitializeLifeTimeService method, as I will use a Singleton instance) 
but, how can I garbage-collect manually this server object on the 
OnStop() method of the service (so as to create a new instance again on 
the OnStart method)?

I have seen that the ILease.CurrentState property is read-only so I 
cannot manually set the Lease as Expired from an external (but not 
remote) object, am I right?

Thanks in advance,

Andrés  [ knocte ]


P.S.: Is anyone in the list using the GenuineChannels library in Mono? 
Does it work? Is there any other stable alternatives? I think I read a 
message from Rafael Teixera where I understood he was using a similar 
solution but had scalability problems...? BTW, will Indigo support this 
kind of channels? Will it be implemented in Mono?

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ASP.NET and Licensing

2006-08-06 Thread Andrés G. Aragoneses [ knocte ]
Andrés G. Aragoneses [ knocte ] escribió:
> Robert Jordan escribió:
>> Hey,
>>
>> Andrés G. Aragoneses [ knocte ] wrote:
>>> einKI.ml escribió:
>>>>> If you don't want to use ASP.NET and/or System.Windows.Form it's up to 
>>>>> you 
>>>>> but note that the fact that there is a closed source implementation of 
>>>>> them 
>>>>> (i.e. Microsoft .NET Framewrok) doesn't mean that you should avoid their 
>>>>> open source implementations (i.e. Mono or Portable.NET, IMHO Mono is much 
>>>>> better:).
>>>> Im just wondering because they are listed as "controversial elements" in
>>>> the FAQ. But since I am somewhat familiar with ASP.NET I think it make
>>>> sense to use it on Linux too.
>>> There are other frameworks that you can use without ASP.NET AFAIK, that 
>>> Miguel has not mentioned (perhaps the ones he has mentioned are too tied 
>>> to the AJAX-thing, I mean, they require JavaScript):
>> Miguel mentioned projects that don't use System.Web at all.
>> Dream depends only on some HttpUtility methods (HtmlEncode, etc.),
>> while Jitzu is completely System.Web independent.
>>
>>> - Maverick.NET (if you use non-ASP.NET methods for the view, such as 
>>> XSLT+XML+XHTML or NVelocity)
>>> [ http://mavnet.sourceforge.net/ ]
>> It depends on System.Web
>>
>>> - CastleProject (the Ruby on Rails port to C#)
>>> [ http://www.castleproject.org/ ]
>> It depends on System.Web, too.
>>
>>> - Spring.NET (I haven't used this one but seems a port of the Spring 
>>> framework from Java to C# that uses AOP)
>>> [ http://www.springframework.net/ ]
>> It depends on System.Web as well.
>>
>>> Using these frameworks you are not only avoiding the use of ASP.NET but 
>> You don't.
> 
> Well, IMHO when we were talking about ASP.NET we were not referring to
> the strict API that it surrounds but to the way a programmer designs web
> applications with it (you know, '.aspx' files, -like tags,
> runat=server attributes...).
> 

I have re-read the message I firstly replied to and now I think that
perhaps the conversation was actually about the strict API...

So I guess these frameworks would be affected if the ASP.NET API became
patent-tied...? :-(

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ASP.NET and Licensing

2006-08-06 Thread Andrés G. Aragoneses [ knocte ]
Robert Jordan escribió:
> Hey,
> 
> Andrés G. Aragoneses [ knocte ] wrote:
>> einKI.ml escribió:
>>>> If you don't want to use ASP.NET and/or System.Windows.Form it's up to you 
>>>> but note that the fact that there is a closed source implementation of 
>>>> them 
>>>> (i.e. Microsoft .NET Framewrok) doesn't mean that you should avoid their 
>>>> open source implementations (i.e. Mono or Portable.NET, IMHO Mono is much 
>>>> better:).
>>> Im just wondering because they are listed as "controversial elements" in
>>> the FAQ. But since I am somewhat familiar with ASP.NET I think it make
>>> sense to use it on Linux too.
>> There are other frameworks that you can use without ASP.NET AFAIK, that 
>> Miguel has not mentioned (perhaps the ones he has mentioned are too tied 
>> to the AJAX-thing, I mean, they require JavaScript):
> 
> Miguel mentioned projects that don't use System.Web at all.
> Dream depends only on some HttpUtility methods (HtmlEncode, etc.),
> while Jitzu is completely System.Web independent.
> 
>> - Maverick.NET (if you use non-ASP.NET methods for the view, such as 
>> XSLT+XML+XHTML or NVelocity)
>> [ http://mavnet.sourceforge.net/ ]
> 
> It depends on System.Web
> 
>> - CastleProject (the Ruby on Rails port to C#)
>> [ http://www.castleproject.org/ ]
> 
> It depends on System.Web, too.
> 
>> - Spring.NET (I haven't used this one but seems a port of the Spring 
>> framework from Java to C# that uses AOP)
>> [ http://www.springframework.net/ ]
> 
> It depends on System.Web as well.
> 
>> Using these frameworks you are not only avoiding the use of ASP.NET but 
> 
> You don't.

Well, IMHO when we were talking about ASP.NET we were not referring to
the strict API that it surrounds but to the way a programmer designs web
applications with it (you know, '.aspx' files, -like tags,
runat=server attributes...).

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ASP.NET and Licensing

2006-07-27 Thread Andrés G. Aragoneses [ knocte ]
einKI.ml escribió:
>> If you don't want to use ASP.NET and/or System.Windows.Form it's up to you 
>> but note that the fact that there is a closed source implementation of them 
>> (i.e. Microsoft .NET Framewrok) doesn't mean that you should avoid their 
>> open source implementations (i.e. Mono or Portable.NET, IMHO Mono is much 
>> better:).
> Im just wondering because they are listed as "controversial elements" in
> the FAQ. But since I am somewhat familiar with ASP.NET I think it make
> sense to use it on Linux too.

There are other frameworks that you can use without ASP.NET AFAIK, that 
Miguel has not mentioned (perhaps the ones he has mentioned are too tied 
to the AJAX-thing, I mean, they require JavaScript):

- Maverick.NET (if you use non-ASP.NET methods for the view, such as 
XSLT+XML+XHTML or NVelocity)
[ http://mavnet.sourceforge.net/ ]

- CastleProject (the Ruby on Rails port to C#)
[ http://www.castleproject.org/ ]

- Spring.NET (I haven't used this one but seems a port of the Spring 
framework from Java to C# that uses AOP)
[ http://www.springframework.net/ ]

Using these frameworks you are not only avoiding the use of ASP.NET but 
besides you use a smarter way of developing web applications (MVC pattern).

Regards,

Andrés  [ knocte ]

-- 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Re: Problem compiling simple app using Mono. Partial declarations of `TestMono.Form1' have conflicting accessibility modifiers

2006-06-15 Thread Andrés G. Aragoneses [ knocte ]

Stacey Levine escribió:
Hello everyone. 

 

I am testing out Mono for an application and am having problems with 
compiling my application.  I built a simple C# application that has one 
form and I put the controls on the form that I am going to need.  My 
little test project is here :  http://www.levineclan.net/testMono.zip


 

I think I have the compile line figured out, and there is a batch file 
in that directory structure which should do it, but when I try to 
compile using mono – I get one error message that I have no idea how to 
fix. The message is below. Anything you could do to help would be 
greatly appreciated.


 

“D:\Projects .NET\TestMono\TestMono>mcs /out:test.exe  Program.cs 
Form1.cs Form1.


Designer.cs Form1.Designer.cs(3,19): error CS0262: Partial declarations 
of `TestMono.Form1'


have conflicting accessibility modifiers

Compilation failed: 1 error(s), 0 warnings “


Hello.

Without seeing the code:

- Partial classes must be declared with the same accessibility keyword 
(public, private, protected)...

- Did you try to compile the program with the MS compiler?

Regards,

Andrés  [ knocte ]

--

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Re: Mono rpm repositories

2006-05-24 Thread Andrés G. Aragoneses [ knocte ]

Andrés G. Aragoneses [ knocte ] escribió:
... (perhaps one person that 
doesn't have Gnome installed and uses wx.NET as graphic library, and 
doesn't want to install any GTK stuff?).


Thinking a little more about this and reading just one of the last 
messages to the list (sent by Tony G), I wonder that some people would 
install mono only for web apps hosting, so this split would be a suggestion:


mono-basic
mono-web
mono-gtk

Doesn't exist a "meta-repository" concept that would allow to subscribe 
to a repository which linked to these three?


Regards,

Andrés  [ knocte ]

--

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Re: Mono rpm repositories

2006-05-24 Thread Andrés G. Aragoneses [ knocte ]

Wade Berrier escribió:

Does anyone have anything against having just one mono channel for each
of these services?  I'm not aware of any advantages of having multiple
channels.

Comments, suggestions?


I agree with you, one unique channel would fit to me perfectly.

The only advantages I see of having multiple channels is when you 
imagine that many people would be interested in some channels, but not 
all of them. And I suppose that every mono developer won't bother having 
installed all channels that you have mentioned, I don't figure a reason 
or requirement for installing only some of them (perhaps one person that 
doesn't have Gnome installed and uses wx.NET as graphic library, and 
doesn't want to install any GTK stuff?).


Regards,

Andrés  [ knocte ]

--

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Re: One mail for two questions !

2006-05-22 Thread Andrés G. Aragoneses [ knocte ]

xiii29 escribió:

Two questions for two advices !

I'm looking for a database which can be embedded in my software ... I 
was wondering about FireBird ??


Also : Mapping Object / Relationnel ==> NHibernate ?


And one answer for two questions:

DB4O [ http://www.db4o.com/ ]

Regards,

Andrés  [ knocte ]

--


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list