This commit is contained in:
2024-05-30 13:02:39 +03:30
parent 0aff395f39
commit ca5d23c43f
4 changed files with 111 additions and 63 deletions
+56 -23
View File
@@ -546,15 +546,13 @@ public:
}
//
int CopyBuffer(
string mTitle, // Required Buffer Title
double &buffer[], // Buffer Dest
int start = 0, // Start
int count = 0 // Count, if 0 Whole
double GetBufferValue(
string mTitle, // Required Buffer Title
int index // Bar Index
)
{
//
int result = 0;
double result = EMPTY_VALUE;
//
// Validate State ...
@@ -563,9 +561,6 @@ public:
return result;
}
//
// Clean(buffer);
//
int bufferIDX = GetBufferIndex(mTitle);
if (bufferIDX < 0)
@@ -577,25 +572,63 @@ public:
Calculate();
//
bool asSeries = ArrayGetAsSeries(buffer);
ArraySetAsSeries(buffer, false);
//
result = ArrayCopy(
buffer,
mBuffers[bufferIDX].values,
start,
start,
count //
);
//
ArraySetAsSeries(buffer, asSeries);
result = mBuffers[bufferIDX].Get(index);
//
return result;
}
//
// int CopyBuffer(
// string mTitle, // Required Buffer Title
// double &buffer[], // Buffer Dest
// int start = 0, // Start
// int count = 0 // Count, if 0 Whole
// )
// {
// //
// int result = 0;
// //
// // Validate State ...
// if (!IsValid())
// {
// return result;
// }
// //
// // Clean(buffer);
// //
// int bufferIDX = GetBufferIndex(mTitle);
// if (bufferIDX < 0)
// {
// return result;
// }
// //
// Calculate();
// //
// bool asSeries = ArrayGetAsSeries(buffer);
// ArraySetAsSeries(buffer, false);
// //
// result = ArrayCopy(
// buffer,
// mBuffers[bufferIDX].values,
// start,
// start,
// count //
// );
// //
// ArraySetAsSeries(buffer, asSeries);
// //
// return result;
// }
//
// Protected ...
protected: