Search Results

Search found 40441 results on 1618 pages for 'function templates'.

Page 7/1618 | < Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >

  • Oracle VM networking under the hood and 3 new templates

    - by Chris Kawalek
    We have a few cool things to tell you about:  First up: have you ever wondered what happens behind the scenes in the network when you Live Migrate your Oracle VM server workload? Or how Oracle VM implements the network infrastructure you configure through your point & click action in the GUI? Really….how do they do this? For an in-depth view of the Oracle VM for x86 Networking model, Look ‘Under the Hood’ at Networking in Oracle VM Server for x86 with our best practices engineer in a blog post on OTN Garage. Next, making things simple in Oracle VM is what we strive every day to deliver to our user community. With that, we are pleased to bring you updates on three new Oracle Application templates: E-Business Suite 12.1.3 for Oracle ExalogicOracle VM templates for Oracle E-Business Suite 12.1.3 (x86 64-bit for Oracle Exalogic Elastic Cloud) contain all the required elements to create an Oracle E-Business Suite R12 demonstration system on an Exalogic server. You can use these templates to quickly build an EBS 12.1.3 demonstration environment, bypassing the operating system and the software install (via the EBS Rapid Install). For further details, please review the announcement.   JD Edwards EnterpriseOne 9.1 and JD Edwards EnterpriseOne Tools 9.1.2.1 for x86 servers and Oracle Exalogic The Oracle VM Templates for JD Edwards EnterpriseOne provide a method to rapidly install JD Edwards EnterpriseOne 9.1  and Tools 9.1.2.1. The complete stack includes Oracle Database 11g R2 and Oracle WebLogic Server 10.3.5 running on Oracle Linux 5. The templates can be installed to Oracle VM Server for x86 release 3.x and to the Oracle Exalogic Elastic Cloud.  PeopleSoft PeopleTools 8.5.2.10 for Oracle Exalogic This virtual deployment package delivers a "quick start" of PeopleSoft Middle-tier template on Oracle Linux for Oracle Exalogic Elastic Cloud. And last, are you wondering why we talk about “fast”, “rapid” when we refer to using Oracle VM templates to virtualize Oracle applications? Read the Evaluator Group Lab Validation report quantifying speeds of deployment up to 10x faster than with VMware vSphere. Or you can also check out our on demand webcast Quantifying the Value of Application-Driven Virtualization.

    Read the article

  • How to do more with Oracle VM Templates

    - by uwes
    On Oracle's Virtualization Blog you can find an interesting post regarding working and using Oracle VM Templates, title is "Opening The Oracle VM Templates Blackbox". Monica Kumar gives a brief explanation what Oracle VM Guest Additions are and how they can help to work smarter with Templates. At the end you will find a hint to join an up coming webcast (October 24th), where you can get more knowledge from experts like Robbie de Meyer or Saar Maoz. Register for the live Webcast. View the whitepaper on Oracle VM Templates Automated Virtual Machine Provisioning.

    Read the article

  • Generic allocator class without variadic templates?

    - by rainer
    I am trying to write a generic allocator class that does not really release an object's memory when it is free()'d but holds it in a queue and returns a previously allocated object if a new one is requested. Now, what I can't wrap my head around is how to pass arguments to the object's constructor when using my allocator (at least without resorting to variadic templates, that is). The alloc() function i came up with looks like this: template <typename... T> inline T *alloc(const &T... args) { T *p; if (_free.empty()) { p = new T(args...); } else { p = _free.front(); _free.pop(); // to call the ctor of T, we need to first call its DTor p->~T(); p = new( p ) T(args...); } return p; } Still, I need the code to be compatible with today's C++ (and older versions of GCC that do not support variadic templates). Is there any other way to go about passing an arbitrary amount of arguments to the objects constructor?

    Read the article

  • Haml Inherit Templates

    - by kjfletch
    I'm using Haml (Haml/Sass 3.0.9 - Classy Cassidy) stand-alone to generate static HTML. I want to create a shared layout template that all my other templates inherit. Layout.haml %html %head %title Test Template %body .Content Content.haml SOMEHOW INHERIT Layout.haml SOMEHOW Change the title of the page "My Content". %p This is my content To produce: Content.html <html> <head> <title>My Content</title> </head> <body> <div class="Content"> <p>This is my content</p> </div> </body> </html> But this doesn't seem possible. I have seen the use of rendering partials when using Haml with Rails but can't find any solution when using Haml stand-alone. Having to put the layout code in all of my templates would be a maintenance nightmare; so my question is how do I avoid doing this? Is there a standard way to solve this problem? Have I missed something fundamental?

    Read the article

  • Building static (but complicated) lookup table using templates.

    - by MarkD
    I am currently in the process of optimizing a numerical analysis code. Within the code, there is a 200x150 element lookup table (currently a static std::vector < std::vector < double ) that is constructed at the beginning of every run. The construction of the lookup table is actually quite complex- the values in the lookup table are constructed using an iterative secant method on a complicated set of equations. Currently, for a simulation, the construction of the lookup table is 20% of the run time (run times are on the order of 25 second, lookup table construction takes 5 seconds). While 5-seconds might not seem to be a lot, when running our MC simulations, where we are running 50k+ simulations, it suddenly becomes a big chunk of time. Along with some other ideas, one thing that has been floated- can we construct this lookup table using templates at compile time? The table itself never changes. Hard-coding a large array isn't a maintainable solution (the equations that go into generating the table are constantly being tweaked), but it seems that if the table can be generated at compile time, it would give us the best of both worlds (easily maintainable, no overhead during runtime). So, I propose the following (much simplified) scenario. Lets say you wanted to generate a static array (use whatever container suits you best- 2D c array, vector of vectors, etc..) at compile time. You have a function defined- double f(int row, int col); where the return value is the entry in the table, row is the lookup table row, and col is the lookup table column. Is it possible to generate this static array at compile time using templates, and how?

    Read the article

  • SQL SERVER – Using RAND() in User Defined Functions (UDF)

    - by pinaldave
    Here is the question I received in email. “Pinal, I am writing a function where we need to generate random password. While writing T-SQL I faced following issue. Everytime I tried to use RAND() function in my User Defined Function I am getting following error: Msg 443, Level 16, State 1, Procedure RandFn, Line 7 Invalid use of a side-effecting operator ‘rand’ within a function. Here is the simplified T-SQL code of the function which I am using: CREATE FUNCTION RandFn() RETURNS INT AS BEGIN DECLARE @rndValue INT SET @rndValue = RAND() RETURN @rndValue END GO I must use UDF so is there any workaround to use RAND function in UDF.” Here is the workaround how RAND() can be used in UDF. The scope of the blog post is not to discuss the advantages or disadvantages of the function or random function here but just to show how RAND() function can be used in UDF. RAND() function is directly not allowed to use in the UDF so we have to find alternate way to use the same function. This can be achieved by creating a VIEW which is using RAND() function and use the same VIEW in the UDF. Here is the step by step instructions. Create a VIEW using RAND function. CREATE VIEW rndView AS SELECT RAND() rndResult GO Create a UDF using the same VIEW. CREATE FUNCTION RandFn() RETURNS DECIMAL(18,18) AS BEGIN DECLARE @rndValue DECIMAL(18,18) SELECT @rndValue = rndResult FROM rndView RETURN @rndValue END GO Now execute the UDF and it will just work fine and return random result. SELECT dbo.RandFn() GO In T-SQL world, I have noticed that there are more than one solution to every problem. Is there any better solution to this question? Please post that question as a comment and I will include it with due credit. Reference: Pinal Dave (http://blog.SQLAuthority.com) Filed under: PostADay, SQL, SQL Authority, SQL Function, SQL Query, SQL Server, SQL Tips and Tricks, T SQL, Technology Tagged: technology

    Read the article

  • Vim: Custom Folding function done, custom highlighting required

    - by sixtyfootersdude
    I have defined a function in vim to properly indent folds. Ie so they look like this: Unfolded this is text also text indented text indented text not indented text folded with default function this is text also text +-- 2 lines: indented text ---------------------------- not indented text folded with my new function this is text also text ++- 2 lines: indented text ---------------------------- not indented text The only problem is the the highlighting is still like this: folded with my new function (highlighting shown with tag) this is text also text <hi> ++- 2 lines: indented text ----------------------------</hi> not indented text I would like the highlighting to start at the ++ and not at the beginning of the line. I have looked in the vim manual but could not find anything like that. One so-so solution I found was to make the background black. highlight Folded ctermbg=black ctermfg=white cterm=bold But this make folds less visible. I have tried several variations of: syn keyword Folded lines syn region Folded ... But I don't think that this is the way that folds are selected. Can anyone offer a suggestion? By the way this is my function to indent the folds: set foldmethod=indent function! MyFoldText() let lines = 1 + v:foldend - v:foldstart let ind = indent(v:foldstart) let spaces = '' let i = 0 while i < ind let i = i+1 let spaces = spaces . ' ' endwhile let linestxt = 'lines' if lines == 1 linestxt = 'line' endif return spaces . '+' . v:folddashes . ' '. lines . ' ' . linestxt . ': ' . getline(v:foldstaendfunction endfunction au BufWinEnter,BufRead,BufNewFile * set foldtext=MyFoldText() By the way thanks to njd for helping me get this function setup.

    Read the article

  • C++: Trouble with templates (C2064)

    - by Rosarch
    I'm having compiler errors, and I'm not sure why. What am I doing wrong here: Hangman.cpp: set<char> Hangman::incorrectGuesses() { // Hangman line 103 return Utils::findAll_if<char>(guesses.begin(), guesses.end(), &Hangman::isIncorrectGuess); } bool Hangman::isIncorrectGuess(char c) { return correctAnswer.find(c) == string::npos; } Utils.h: namespace Utils { void PrintLine(const string& line, int tabLevel = 0); string getTabs(int tabLevel); template<class result_t, class Predicate> std::set<result_t> findAll_if(typename std::set<result_t>::iterator begin, typename std::set<result_t>::iterator end, Predicate pred) { std::set<result_t> result; // utils line 16 return detail::findAll_if_rec<result_t>(begin, end, pred, result); } } namespace detail { template<class result_t, class Predicate> std::set<result_t> findAll_if_rec(typename std::set<result_t>::iterator begin, typename std::set<result_t>::iterator end, Predicate pred, std::set<result_t> result) { // utils line 25 typename std::set<result_t>::iterator nextResultElem = find_if(begin, end, pred); if (nextResultElem == end) { return result; } result.insert(*nextResultElem); return findAll_if_rec(++nextResultElem, end, pred, result); } } This produces the following compiler errors: algorithm(83): error C2064: term does not evaluate to a function taking 1 arguments algorithm(95) : see reference to function template instantiation '_InIt std::_Find_if<std::_Tree_unchecked_const_iterator<_Mytree>,_Pr>(_InIt,_InIt,_Pr)' being compiled 1> with 1> [ 1> _InIt=std::_Tree_unchecked_const_iterator<std::_Tree_val<std::_Tset_traits<char,std::less<char>,std::allocator<char>,false>>>, 1> _Mytree=std::_Tree_val<std::_Tset_traits<char,std::less<char>,std::allocator<char>,false>>, 1> _Pr=bool (__thiscall Hangman::* )(char) 1> ] utils.h(25) : see reference to function template instantiation '_InIt std::find_if<std::_Tree_const_iterator<_Mytree>,Predicate>(_InIt,_InIt,_Pr)' being compiled 1> with 1> [ 1> _InIt=std::_Tree_const_iterator<std::_Tree_val<std::_Tset_traits<char,std::less<char>,std::allocator<char>,false>>>, 1> _Mytree=std::_Tree_val<std::_Tset_traits<char,std::less<char>,std::allocator<char>,false>>, 1> Predicate=bool (__thiscall Hangman::* )(char), 1> _Pr=bool (__thiscall Hangman::* )(char) 1> ] utils.h(16) : see reference to function template instantiation 'std::set<_Kty> detail::findAll_if_rec<result_t,Predicate>(std::_Tree_const_iterator<_Mytree>,std::_Tree_const_iterator<_Mytree>,Predicate,std::set<_Kty>)' being compiled 1> with 1> [ 1> _Kty=char, 1> result_t=char, 1> Predicate=bool (__thiscall Hangman::* )(char), 1> _Mytree=std::_Tree_val<std::_Tset_traits<char,std::less<char>,std::allocator<char>,false>> 1> ] hangman.cpp(103) : see reference to function template instantiation 'std::set<_Kty> Utils::findAll_if<char,bool(__thiscall Hangman::* )(char)>(std::_Tree_const_iterator<_Mytree>,std::_Tree_const_iterator<_Mytree>,Predicate)' being compiled 1> with 1> [ 1> _Kty=char, 1> _Mytree=std::_Tree_val<std::_Tset_traits<char,std::less<char>,std::allocator<char>,false>>, 1> Predicate=bool (__thiscall Hangman::* )(char) 1> ]

    Read the article

  • django templates array assignment

    - by Hulk
    The following is in views: rows=query.evaluation_set.all() row_arr = [] for row in rows: row_arr.append(row.row_details) dict.update({'row_arr' : row_arr ,'col_arr' : col_arr}) return render_to_response('valuemart/show.html',context_instance=RequestContext(request,{'dict': dict})) How to extract the row_Arr array in the templates in javascript and list out all its values.row_Arr contains data of a column <script> var row_arr = '{{dict.row_arr}}'; //extract values here </script> Thanks..

    Read the article

  • Default template arguments for function templates

    - by Arman
    Why are default template arguments only allowed on class templates? Why can't we define a default type in a member function template? For example: struct mycclass { template<class T=int> void mymember(T* vec) { // ... } }; Instead, C++ forces that default template arguments are only allowed on a class template.

    Read the article

  • Good Administration Center Templates

    - by Alec Smart
    Hello, This may not be a programming question per se. But I am wondering what template do you use for your sites/webapps admin centers. Am looking primarily at free templates that give a basic structure. I know I can build my own, but I haven't had too much success in something that works for all my webapps/sites. Wondering if there is something nice and comprehensive available. Thank you for your time.

    Read the article

  • Django templates tag error

    - by Hulk
    def _table_(request,id,has_permissions): dict = {} dict.update(get_newdata(request,rid)) return render_to_response('home/_display.html',context_instance=RequestContext(request,{'dict': dict, 'rid' : rid, 'has_permissions' : str(has_permissions)})) In templates the code is as, {% if has_permissions == "1" %} <input type="button" value="Edit" id="edit" onclick="javascript:edit('{{id}}')" style="display:inline;"/>&nbsp;&nbsp;&nbsp;&nbsp; {% endif %} There is a template error in has_permissions line. Can any 1 tell me what is wrong here. has_permissions has the value 1 or 0.

    Read the article

  • Is it possible to have 'sub-templates' when using MailDefinition

    - by Dan
    I am using the MailDefinition class to create html emails for my site. The only problem I am having is that there is alot of repetition in the string templates. For example the email footer along with all the associated html and css has to be repeated in each template type. Is there a way to have sub-template? or some mechanism for avoiding this repetition?

    Read the article

  • Where are the function address literals in c++?

    - by academicRobot
    First of all, maybe literals is not the right term for this concept, but its the closest I could think of (not literals in the sense of functions as first class citizens). <UPDATE> After some reading with help from answer by Chris Dodd, what I'm looking for is literal function addresses as template parameters. Chris' answer indicates how to do this for standard functions, but how can the addresses of member functions be used as template parameters? Since the standard prohibits non-static member function addresses as template parameters (c++03 14.3.2.3), I suspect the work around is quite complicated. Any ideas for a workaround? Below the original form of the question is left as is for context. </UPDATE> The idea is that when you make a conventional function call, it compiles to something like this: callq <immediate address> But if you make a function call using a function pointer, it compiles to something like this: mov <memory location>,%rax callq *%rax Which is all well and good. However, what if I'm writing a template library that requires a callback of some sort with a specified argument list and the user of the library is expected to know what function they want to call at compile time? Then I would like to write my template to accept a function literal as a template parameter. So, similar to template <int int_literal> struct my_template {...};` I'd like to write template <func_literal_t func_literal> struct my_template {...}; and have calls to func_literal within my_template compile to callq <immediate address>. Is there a facility in C++ for this, or a work around to achieve the same effect? If not, why not (e.g. some cataclysmic side effects)? How about C++0x or another language? Solutions that are not portable are fine. Solutions that include the use of member function pointers would be ideal. I'm not particularly interested in being told "You are a <socially unacceptable term for a person of low IQ>, just use function pointers/functors." This is a curiosity based question, and it seems that it might be useful in some (albeit limited) applications. It seems like this should be possible since function names are just placeholders for a (relative) memory address, so why not allow more liberal use (e.g. aliasing) of this placeholder. p.s. I use function pointers and functions objects all the the time and they are great. But this post got me thinking about the don't pay for what you don't use principle in relation to function calls, and it seems like forcing the use of function pointers or similar facility when the function is known at compile time is a violation of this principle, though a small one. Edit The intent of this question is not to implement delegates, rather to identify a pattern that will embed a conventional function call, (in immediate mode) directly into third party code, possibly a template.

    Read the article

< Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >