Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. Is this an acceptable practice?

Is this an acceptable practice?

Scheduled Pinned Locked Moved The Lounge
jsonquestion
55 Posts 16 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Colborne_Greg

    <System.Runtime.Serialization.DataMember>
    Private mLastUpdated As DateTime, _
    mLastUpdatedBy As String, _
    mClearanceRequired As Int64, _
    mClearanceIsRequired As Boolean

    Visual basic code; class members for serialization - declaring a group of variables as data members.

    J Offline
    J Offline
    JimmyRopes
    wrote on last edited by
    #6

    Please ask in the proper forum.

    The report of my death was an exaggeration - Mark Twain
    Simply Elegant Designs JimmyRopes Designs
    I'm on-line therefore I am. JimmyRopes

    C F 2 Replies Last reply
    0
    • C Colborne_Greg

      <System.Runtime.Serialization.DataMember>
      Private mLastUpdated As DateTime, _
      mLastUpdatedBy As String, _
      mClearanceRequired As Int64, _
      mClearanceIsRequired As Boolean

      Visual basic code; class members for serialization - declaring a group of variables as data members.

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #7

      System.Runtime.Serialization sucks.

      C 1 Reply Last reply
      0
      • C Colborne_Greg

        <System.Runtime.Serialization.DataMember>
        Private mLastUpdated As DateTime, _
        mLastUpdatedBy As String, _
        mClearanceRequired As Int64, _
        mClearanceIsRequired As Boolean

        Visual basic code; class members for serialization - declaring a group of variables as data members.

        L Offline
        L Offline
        Lost User
        wrote on last edited by
        #8

        Whehe; the compiler accepts it - what trouble are you having with it, and what makes it unacceptable to you?

        Bastard Programmer from Hell :suss: If you can't read my code, try converting it here[^]

        D C 2 Replies Last reply
        0
        • L Lost User

          Whehe; the compiler accepts it - what trouble are you having with it, and what makes it unacceptable to you?

          Bastard Programmer from Hell :suss: If you can't read my code, try converting it here[^]

          D Offline
          D Offline
          Dave Kreskowiak
          wrote on last edited by
          #9

          I have yet to find a compiler that has to support and maintain the code it compiles.

          A guide to posting questions on CodeProject

          How to debug small programs
          Dave Kreskowiak

          C 1 Reply Last reply
          0
          • P Peter_in_2780

            I'm not commenting on whether the code is acceptable, but I am suggesting that posting this question in the Lounge might not be. Cheers, Peter

            Software rusts. Simon Stephenson, ca 1994. So does this signature. me, 2012

            C Offline
            C Offline
            Colborne_Greg
            wrote on last edited by
            #10

            For lazing about and discussing anything in a software developer's life that takes your fancy. The Lounge is rated PG. If you're about to post something you wouldn't want your kid sister to read then don't post it. No flame wars, no abusive conduct and please don't post ads. What do you think is a valid thing to post about in the code project?

            1 Reply Last reply
            0
            • J JimmyRopes

              Please ask in the proper forum.

              The report of my death was an exaggeration - Mark Twain
              Simply Elegant Designs JimmyRopes Designs
              I'm on-line therefore I am. JimmyRopes

              C Offline
              C Offline
              Colborne_Greg
              wrote on last edited by
              #11

              For lazing about and discussing anything in a software developer's life that takes your fancy. The Lounge is rated PG. If you're about to post something you wouldn't want your kid sister to read then don't post it. No flame wars, no abusive conduct and please don't post ads. This tickles my fancy.

              Richard Andrew x64R 1 Reply Last reply
              0
              • L Lost User

                Whehe; the compiler accepts it - what trouble are you having with it, and what makes it unacceptable to you?

                Bastard Programmer from Hell :suss: If you can't read my code, try converting it here[^]

                C Offline
                C Offline
                Colborne_Greg
                wrote on last edited by
                #12

                Its valid code. Coding practices is the topic.

                P 1 Reply Last reply
                0
                • L Lost User

                  System.Runtime.Serialization sucks.

                  C Offline
                  C Offline
                  Colborne_Greg
                  wrote on last edited by
                  #13

                  Indeed.

                  1 Reply Last reply
                  0
                  • D Dave Kreskowiak

                    I have yet to find a compiler that has to support and maintain the code it compiles.

                    A guide to posting questions on CodeProject

                    How to debug small programs
                    Dave Kreskowiak

                    C Offline
                    C Offline
                    Colborne_Greg
                    wrote on last edited by
                    #14

                    Visual Studio 2013 for windows 8.1 apps

                    D 1 Reply Last reply
                    0
                    • C Colborne_Greg

                      For lazing about and discussing anything in a software developer's life that takes your fancy. The Lounge is rated PG. If you're about to post something you wouldn't want your kid sister to read then don't post it. No flame wars, no abusive conduct and please don't post ads. This tickles my fancy.

                      Richard Andrew x64R Offline
                      Richard Andrew x64R Offline
                      Richard Andrew x64
                      wrote on last edited by
                      #15

                      Colborne_Greg wrote:

                      This tickles my fancy.

                      You conveniently left out:

                      Quote:

                      Technical discussions are welcome, but if you need specific help please use the programming forums.

                      The difficult we do right away... ...the impossible takes slightly longer.

                      C 1 Reply Last reply
                      0
                      • Richard Andrew x64R Richard Andrew x64

                        Colborne_Greg wrote:

                        This tickles my fancy.

                        You conveniently left out:

                        Quote:

                        Technical discussions are welcome, but if you need specific help please use the programming forums.

                        The difficult we do right away... ...the impossible takes slightly longer.

                        C Offline
                        C Offline
                        Colborne_Greg
                        wrote on last edited by
                        #16

                        I DO NOT NEED HELP Quit behaving like you know what the fook is going on. THE QUESTION IS - is this an acceptable practice, please learn to read English before getting on my case.

                        D J 2 Replies Last reply
                        0
                        • C Colborne_Greg

                          Visual Studio 2013 for windows 8.1 apps

                          D Offline
                          D Offline
                          Dave Kreskowiak
                          wrote on last edited by
                          #17

                          And what does that have to do with what I said??

                          A guide to posting questions on CodeProject

                          How to debug small programs
                          Dave Kreskowiak

                          C 1 Reply Last reply
                          0
                          • C Colborne_Greg

                            I DO NOT NEED HELP Quit behaving like you know what the fook is going on. THE QUESTION IS - is this an acceptable practice, please learn to read English before getting on my case.

                            D Offline
                            D Offline
                            Dave Kreskowiak
                            wrote on last edited by
                            #18

                            Your question will only get opinions for an answer. The answer all depends on who you ask. I hate it because it isn't explicit. It requires you to know how the compiler is going to behave.

                            A guide to posting questions on CodeProject

                            How to debug small programs
                            Dave Kreskowiak

                            C 1 Reply Last reply
                            0
                            • D Dave Kreskowiak

                              And what does that have to do with what I said??

                              A guide to posting questions on CodeProject

                              How to debug small programs
                              Dave Kreskowiak

                              C Offline
                              C Offline
                              Colborne_Greg
                              wrote on last edited by
                              #19

                              That's the compiler and libraries used for the code.

                              D 1 Reply Last reply
                              0
                              • D Dave Kreskowiak

                                Your question will only get opinions for an answer. The answer all depends on who you ask. I hate it because it isn't explicit. It requires you to know how the compiler is going to behave.

                                A guide to posting questions on CodeProject

                                How to debug small programs
                                Dave Kreskowiak

                                C Offline
                                C Offline
                                Colborne_Greg
                                wrote on last edited by
                                #20

                                It is only one line of code, broken into multiple lines via the _ character.

                                <System.Runtime.Serialization.DataMember>
                                Private mLastUpdated As DateTime, mLastUpdatedBy As String, mClearanceRequired As Int64, mClearanceIsRequired As Boolean

                                D 1 Reply Last reply
                                0
                                • C Colborne_Greg

                                  That's the compiler and libraries used for the code.

                                  D Offline
                                  D Offline
                                  Dave Kreskowiak
                                  wrote on last edited by
                                  #21

                                  Considering I wasn't commenting on that at all, your post makes no sense. I was merely commenting that the compiler is never responsible for supporting the application, YOU are.

                                  A guide to posting questions on CodeProject

                                  How to debug small programs
                                  Dave Kreskowiak

                                  C 1 Reply Last reply
                                  0
                                  • C Colborne_Greg

                                    It is only one line of code, broken into multiple lines via the _ character.

                                    <System.Runtime.Serialization.DataMember>
                                    Private mLastUpdated As DateTime, mLastUpdatedBy As String, mClearanceRequired As Int64, mClearanceIsRequired As Boolean

                                    D Offline
                                    D Offline
                                    Dave Kreskowiak
                                    wrote on last edited by
                                    #22

                                    So what? It seems like you're doing this and your looking for absolution from the community. Again, it's a matter of opinion and in a real environment with coding standards, what you've done may be outlawed.

                                    A guide to posting questions on CodeProject

                                    How to debug small programs
                                    Dave Kreskowiak

                                    C 1 Reply Last reply
                                    0
                                    • C Colborne_Greg

                                      <System.Runtime.Serialization.DataMember>
                                      Private mLastUpdated As DateTime, _
                                      mLastUpdatedBy As String, _
                                      mClearanceRequired As Int64, _
                                      mClearanceIsRequired As Boolean

                                      Visual basic code; class members for serialization - declaring a group of variables as data members.

                                      F Offline
                                      F Offline
                                      Fabio Franco
                                      wrote on last edited by
                                      #23

                                      I don't see any problem with it, as a matter of fact it actually reminds me of C++ member declaration.

                                      To alcohol! The cause of, and solution to, all of life's problems - Homer Simpson ---- Our heads are round so our thoughts can change direction - Francis Picabia

                                      C 1 Reply Last reply
                                      0
                                      • C Colborne_Greg

                                        <System.Runtime.Serialization.DataMember>
                                        Private mLastUpdated As DateTime, _
                                        mLastUpdatedBy As String, _
                                        mClearanceRequired As Int64, _
                                        mClearanceIsRequired As Boolean

                                        Visual basic code; class members for serialization - declaring a group of variables as data members.

                                        D Offline
                                        D Offline
                                        Dan Neely
                                        wrote on last edited by
                                        #24

                                        "It is a vessel of fertilizer, and none may abide its strength."

                                        Did you ever see history portrayed as an old man with a wise brow and pulseless heart, waging all things in the balance of reason? Is not rather the genius of history like an eternal, imploring maiden, full of fire, with a burning heart and flaming soul, humanly warm and humanly beautiful? --Zachris Topelius Training a telescope on one’s own belly button will only reveal lint. You like that? You go right on staring at it. I prefer looking at galaxies. -- Sarah Hoyt

                                        C 1 Reply Last reply
                                        0
                                        • C Colborne_Greg

                                          <System.Runtime.Serialization.DataMember>
                                          Private mLastUpdated As DateTime, _
                                          mLastUpdatedBy As String, _
                                          mClearanceRequired As Int64, _
                                          mClearanceIsRequired As Boolean

                                          Visual basic code; class members for serialization - declaring a group of variables as data members.

                                          G Offline
                                          G Offline
                                          Gates VP
                                          wrote on last edited by
                                          #25

                                          At a first glance, I find this confusing. In particular because the DataMember attribute actually accepts a constructor parameter. - So if I set the constructor parameter, which field does it apply to? - Likewise, if you want to switch out serializers and use something like Protocol Buffers this syntax simply won't translate. You would need to break out each one as the constructor is required. - On top of this all, there's a mixing of types. I'm not a big fan of the "multi-declaration" syntax, especially when it doesn't save any actual lines like this example. But there are some cases where it is useful. That stated, if you're mixing types on the "multi-declarations", it's time split them out. I wouldn't call this "unacceptable" practice, especially in the context of firing someone over this. I would however call this "non-standard" and "confusing" and ask that it be changed.

                                          C F 2 Replies Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups