Creating a custom .config file in asp.net [closed] - web-config

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 years ago.
Improve this question
Is there a way I can create a blah.config file in asp.net, and access the name/value pairs of nodes the same way you access items in in a regular web.config file?
(the idea is to not have to write any custom code for this).

Chris shows one way to "externalize" part of your configuration. That works fine for certain scenarios. If you need more, you'll need to dig in a bit deeper.
For that, you should definitely check out Jon Rista's three-part series on .NET 2.0 configuration up on CodeProject.
Unraveling the mysteries of .NET 2.0 configuration
Decoding the mysteries of .NET 2.0 configuration
Cracking the mysteries of .NET 2.0 configuration
Highly recommended, well written and extremely helpful! He shows how to create and use custom configuration sections, and goes on to explain how to use your own blah.config instead of or in addition to standard .NET config files.
Marc

Use the "file" attribute of the appSettings block, like so:
<appSettings file="user.config">
<add key="Test1" value="Generic1" />
<add key="Test2" value="Generic2" />
</appSettings>
Further explanation available here.

Related

Swift Classes in One File [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 6 years ago.
Improve this question
I know in python it is good practice to have a models.py and put all of an application's model classes in there. Does the same apply to swift or is it better to have a separate file for each model class?
Thanks!
Apple recommends to have separate files for each model class however it's possible to use the "Python style"
Assuming that your project is average..I would put each of your models in a separate file. Sometimes you end up with some small files, but I would rather go through that then some massive file where I can't find anything.
There is no single correct answer to this question, but Swift's system of controlling access suggests that it is not the best practice.
Properties and methods marked private are only visible within the same source file. If you put all of your model classes into a single file, they will all have access to each others' private methods and properties, which defeats the whole purpose of marking something private.

Logging in Java in 2015 - what does a properly configured environment look like? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 5 years ago.
Improve this question
My Eclipse/Tomcat project is a tangled mess of slf4j, log4j, JULI, logback, etc. As a result my console has an abundance of useless messages from various libraries and it is hard to get the logging output I want from my own code. I've resorted to using System.out to get stuff done.
The server deployment environment is in similar bad shape.
What I'm wondering is, where can I find a reference implementation, or checklist, that outlines what a correct configuration of all these logging frameworks is supposed to look like?
I don't know of any examples, but you should try to use slf4j instead of a mixture of logging frameworks. What you can do is use bridges to slf4j instead of the actual libraries. See slf4j documentation on bridges.
There is a slight inconvenience with JUL, but little effort you should be able to control that as well.
I have found I don't like the "Internet wisdom" on this which is exemplified by the diagrams at slf4j.org: it's more complicated than it needs to be, and doesn't address technical debt. Here are my recommendations:
Get rid of log4j. No modern libraries require it, my app shouldn't either.
Bridge slf4j to jdk14.
Bind jcl to jdk14 natively (do not use the jcl-over-slf4j bridge)
Adopt native jdk14 logging in all new code
This seems to provide the simplest configuration with smallest number of config files and directives and fewest surprises.

Leadtools v13 annotations [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I'm currently working on an enhancement for a commercial utility that involves annotations with respect to LeadTools v13. In terms of LeadTools, it would appear that most things start off with the raster object, but without documentation for V13, it's somewhat of a challenge to make heads or tails of how to proceed in terms of reading the annotation files in.
If anyone has any code examples for such an old version, any help would be appreciated.
LEADTOOLS support don't have online documentation for this old version of LEADTOOLS. However, our help files shipped with the toolkit includes code examples for most of our functions including the annotations functions. You can find our help files in the following folder:
[LEADTOOLS 13 Folder]\Help

zf scaffolding tools [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
Are there any open source projects any of you would recommend to follow or contribute toward, including those already documented among the zf contributors, to add zend framework scaffolding of crud functionality for rapid development as found in most competitors frameworks?
As a contributor of not only the language and framework, but also as a user of zf on a daily basis, I know this is a topic of interest and I feel professional developers like you would find here would have something to contribute toward my question and finding a library that is underway that can be contributed to.
Still pointing out one Repo that generates a new module with folder structure, config and module class
Inforbiro / ZF2-Code-Generator
While personally i feel this to be more troublesome than doing it by hand, it's a first step only. Though it appears development already has stopped, for now.
If ever (and i'm pretty sure) there will be a ZF2-Tool, you'll find it at the zf-commons repository
ZF-Commons
Sorry, apparently this is not an appropriate question to ask, i've learned, at stackoverflow. Didn't realize this kind of question wasn't allowed since it doesn't have code I guess.

Zend Framework SEO tips [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about programming within the scope defined in the help center.
Closed 3 years ago.
Improve this question
I've done basic work suggested by Google and others to improve Google ranking. What are the 'specific' things I should do with Zend Framework (or in general any MVC architecture) to make it better? It seems all the usual methods aren't working that well with Zend Framework.
There is nothing special to ZF or any other MVC framework. The only ZF-specific thing I can think of is that in ZF you can use the router and routes to create those nice looking URLs that people claim to be SEO friendly. Also, you can use the headMeta helper to create metatags but that's basically all...
There is no magic trick to it.
With Zend_Navigation you can also easily create XML Sitemaps which can help to index your website.