codebase

What's the best way to become familiar with a large codebase? [closed]

扶醉桌前 提交于 2019-11-29 19:03:42
Joining an existing team with a large codebase already in place can be daunting. What's the best approach; Broad; try to get a general overview of how everything links together, from the code Narrow; focus on small sections of code at a time, understanding how they work fully Pick a feature to develop and learn as you go along Try to gain insight from class diagrams and uml, if available (and up to date) Something else entirely? I'm working on what is currently an approx 20k line C++ app & library (Edit: small in the grand scheme of things!). In industry I imagine you'd get an introduction by

How can I convert Assembly.CodeBase into a filesystem path in C#?

99封情书 提交于 2019-11-29 02:47:29
I have a project that stores templates in a \Templates folder next to the DLLs and EXE. I want to determine this file path at runtime, but using a technique that will work inside a unit test as well as in production (and I don't want to disable shadow-copying in NUnit!) Assembly.Location is no good because it returns the shadow-copied assembly's path when running under NUnit. Environment.CommandLine is also of limited use because in NUnit et al it returns the path to NUnit, not to my project. Assembly.CodeBase looks promising, but it's a UNC path: file:///D:/projects/MyApp/MyApp/bin/debug

What's the best way to become familiar with a large codebase? [closed]

十年热恋 提交于 2019-11-28 13:16:41
问题 As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. Closed 6 years ago . Joining an existing team with a large codebase already in place can be daunting. What's the best approach; Broad; try to get a general

PHP CodeBase: 求最近一个周一和上周一的日期

末鹿安然 提交于 2019-11-27 19:29:06
有时候,会有这么一些需求:在每周的周一会更新一些内容,那么我要获取本周周一的数据,或者上周周一的数据,那么就需要知道本周或上周周一的日期了。对于程序来说,需求就变成了:这周的周一是几号?或者说,上周一是几号? 先来求一下本周周一的 日期 : $ts = time(); $this_monday = this_monday($ts); echo date('Y-m-d H:i:s', $this_monday); //这个星期的星期一 // @$timestamp ,某个星期的某一个时间戳,默认为当前时间 // @is_return_timestamp ,是否返回时间戳,否则返回时间格式 function this_monday($timestamp=0,$is_return_timestamp=true){ static $cache ; $id = $timestamp.$is_return_timestamp; if(!isset($cache[$id])){ if(!$timestamp) $timestamp = time(); $monday_date = date('Y-m-d', $timestamp-86400*date('w',$timestamp)+(date('w',$timestamp)>0?86400:-/*6*86400*/518400)); if(

How can I convert Assembly.CodeBase into a filesystem path in C#?

跟風遠走 提交于 2019-11-27 17:04:16
问题 I have a project that stores templates in a \Templates folder next to the DLLs and EXE. I want to determine this file path at runtime, but using a technique that will work inside a unit test as well as in production (and I don't want to disable shadow-copying in NUnit!) Assembly.Location is no good because it returns the shadow-copied assembly's path when running under NUnit. Environment.CommandLine is also of limited use because in NUnit et al it returns the path to NUnit, not to my project.