Hi,
in the .NET Framework Class Library there is the following text in the
"Remarks"-section:
"Use this method for objects that are immutable, but for which you want to
provide changeable properties."
.... objects that are immutable ... - what does this mean? Can someone please
insert here an example?
thx & bye
Oskar 3 1424
Oskar Vaia wrote: Hi,
in the .NET Framework Class Library there is the following text in the "Remarks"-section:
"Use this method for objects that are immutable, but for which you want to provide changeable properties."
... objects that are immutable ... - what does this mean? Can someone please insert here an example?
An immutable object is an object who's internal state cannot change after it
has been created. Strings are an example of immutable objects in the .Net
Framework. You can never change the value of an existing String object,
since all its methods return a new String object, leaving the original
object intact.
--
Sven Groot http://unforgiven.bloghorn.com
Hi Oskar,
A String is immutable, a change will mean that it is written on a new place
and the old one is destroyed when the Garbadge Collecter does his work.
I hope this clears it a little bit?
Cor Hi,
in the .NET Framework Class Library there is the following text in the "Remarks"-section:
"Use this method for objects that are immutable, but for which you want to provide changeable properties."
... objects that are immutable ... - what does this mean? Can someone
please insert here an example?
hi,
thx for your answers.
ok, but what does it so mean in the context with the
Typeconverter.C reateInstance-Method?
bye
Oskar This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: João Santa Bárbara |
last post by:
Hi all
i have a class that i have made and i made an Typeconverter as well, and my
problem is
the code genereated in my form is
Dim ClassTest1 As TestApplication.ClassTest = New TestApplication.ClassTest
Me.MyClassTest = ClassTest1
Wich is quite good, but my problem is in my property browser i cannot change
any of my properties
|
by: João Santa Bárbara |
last post by:
Hi all
i have a class that i have made and i made an Typeconverter as well, and my
problem is
the code genereated in my form is
Dim ClassTest1 As TestApplication.ClassTest = New TestApplication.ClassTest
Me.MyClassTest = ClassTest1
Wich is quite good, but my problem is in my property browser i cannot change
any of my properties
|
by: kw |
last post by:
I'm getting different behavior from what I would expect and was hoping
someone could clue me in. At run time I need to examine a property of an
object for a custom TypeConverter, then use that converter on a value.
Here's the deal:
object
attrs=(object)PropertyInfo.GetCustomAttributes(typeof(TypeConverterAttribu
te),false);
|
by: Sky Sigal |
last post by:
(PS: Cross post from microsoft.pulic.dotnet.framework.aspnet.webcontrols)
I've been looking lately for a way to keep the Properties panel for Controls
'clean'...
My goal is to keep similar public properties of a custom Control neatly tied
together -- rather than all over the IDE.
One such set of values that will rarely be changed, so should have little
priority in the IDE Properties panel, and therefore a good candidate for
|
by: Eric Hoch |
last post by:
Hello,
I'm writing a TypeConverter for a class which inherits arraylist, but
deserializing it always results in an arraylist, which causes an
InvalidCastException. If anyone can point out what I'm doing wrong here,
I'd really appreciate it.
The class:
<TypeConverter(GetType(CXMLObjectListConverter))> _
| |
by: Kent Boogaart |
last post by:
*tried this already on the buildingcontrols newsgroup but didn't get a
response*
Hi,
As far as I can tell, it is not possible to use the TypeConverter
infrastructure with generic types. Say you have this type:
public struct Id<T> where T : IComparable
{ ... }
|
by: swartzbill2000 |
last post by:
Hello,
I have a TypeConverter for converting between this Enum and Strings.
Public Enum DeviceNameEnum
dnNone
dn2500
dnMirror
End Enum 'DeviceNameEnum
|
by: Rolf Welskes |
last post by:
Hello,
the problem seems to be complex and is in all developments of web-controls
which uses own TypeConverter.
For this I have here a simple demo-program of the problem:
The Control-code: A class MyString which is a class which is similar to a
string
public class MyString
{
|
by: --== Alain ==-- |
last post by:
Hi,
I 'm facing an interesting issue regarding a property and its TypeConverter.
When i do not attach a TypeConverter to this property, all custom
properties of my custom control are displayed in Test Container.
Since i attached this TypeConverter to my property, ALL custom
properties (properties implemented by myself) are not displayed in Test
Container.
|
by: Larry Smith |
last post by:
Hi there,
Can anyone provide any insight on why MSFT introduced
"TypeConverter.GetProperties()". There are two classes for dealing with
metadata in .NET, 'Type" and "TypeDescriptor". Each has a "GetProperites()"
method so why complicate the situation even more than it already is by
adding a "GetProperties()" method to "TypeConverter". The class is supposed
to be for converting types so "GetProperties()" seems misplaced and
redundant (as...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
| |
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
| |
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |