B
Brandon McCombs
I am developing an LDAP client that will allow a user to search and
browse a directory server. I currently have the main window spawn a
settings dialog that stores user auth. credentials into a class I
created to hold that type of data. I then am attempting to pass an
instance of that credential clas around to use in various places in the
code when I have to authenticate for a directory context connection.
That worked until I started having to pass it between classes and I
figured there had to be a better way.
I started wondering whether this would be a good time to start learning
how to use a props file. I'm currently already using a file though to
store my user credentials and that data gets put into my credential
class instance so I'd end up with the same problem I think of having to
share data across classes instead of just methods.
Is the only way to share this data to pass my credentials class instance
into the constructor of any class that needs access to it or is there a
cleaner way of doing that like a props file?
thanks for any tips
browse a directory server. I currently have the main window spawn a
settings dialog that stores user auth. credentials into a class I
created to hold that type of data. I then am attempting to pass an
instance of that credential clas around to use in various places in the
code when I have to authenticate for a directory context connection.
That worked until I started having to pass it between classes and I
figured there had to be a better way.
I started wondering whether this would be a good time to start learning
how to use a props file. I'm currently already using a file though to
store my user credentials and that data gets put into my credential
class instance so I'd end up with the same problem I think of having to
share data across classes instead of just methods.
Is the only way to share this data to pass my credentials class instance
into the constructor of any class that needs access to it or is there a
cleaner way of doing that like a props file?
thanks for any tips