Code simplicity and forethought for reuse. It requires more effort up front, but boy does it ever pay off in the long run! It’s the easiest way to simplify and maintain solutions and along with clever refactoring, is the easiest way to understand the code and make changes or add additional functionality in the future.
I’ve been a personal witness to clean refactored code which has been copied and pasted in each and every Unity Script that requires it. Using the example of 10 Unity Scripts, this means that if a change needs to be made to the common “GetKeywordValue” Extension Method, then you would have to make that change 10 times. Unless you’re paid hourly and enjoy repetitive, time consuming tasks with a high probability for error, you need to become familiar with using Library scripts.
Again, the same lines of code should never be repeated in different codebases. Instead, put these lines of code in a shared library. Library scripts allow you to create a single method which can be called from multiple sources. They allow you to REDUCE the amount of code in that source code and they allow you to efficiently REUSE generic code.
Think now into the future: You are assigned another project which requires you to get the value of a few Keywords on the document. Rather than trying to remember the exact OnBase Unity API methods to call in order to get the Keyword Value or having to rewrite code you’ve already written previously, you can easily call your own “GetKeywordValue” Extension Method that you created back in 2014. Or let’s say you get a new developer on the team that takes on the project. Refactoring and reusing code ensures that all developers in an organization follow the same development pattern and allows these same developers to easily pick up another team member’s code and understand it or make changes.
Sure this specific “GetKeywordValue” example Extension Method is pretty simplistic, but imagine the same concept applied to something more elaborate. You can build a library method that accepts an image document and returns a data stream of a PDF document. You can build another library method that accepts an OnBase document and an n-length Dictionary of Keyword Types and Values and adds those values to the document. In fact, the development team at Kiriworks has already done the latter. We are committed to our own philosophy of reducing, reusing, and refactoring code and it has made a huge impact on our efficiency.
WorkView|Case Manager is a data-centric business process solution that allows you to create custom applications to meet business needs that uses your existing OnBase database. There are 6 essential parts to WorkView. WorkView can also utilize Workflow to move a record/object just like it was a document. Records/objects can be evaluated in Workflow Rules to determine what steps in the […]
In my few years with the ECM industry I’ve heard various recommendations, discussions, comments and frustrations about the process of evaluating a company’s ECM needs, establishing a project plan, implementation and of course the ultimate go-live. It can be quite the process for both the vendor and the customer. I decided to ask a few company representatives who recently underwent […]
Have you shopped at a Target store during the last holiday season? Have you called or e-mailed your Valentine lately? Have you seen a doctor during this especially nasty flu season? If you’ve been involved in any of these activities or a myriad of other activities where you imparted some of your most sensitive personal data (financial, personal or health […]
Support for Windows XP will end on April 8th 2014. If you have an older scanner that is connected to a PC running XP, you may not be aware that your scanner will not work and/or be supported with Windows 7 or Windows 8. If your scanner is connected to the PC via SCSI (a thicker cable running from the […]