class ResourceDTO {
String resourceName;
List<AssociateResource> associateResource = new ArrayList<AssociateResource>;
// getter-setter...
}
class AssociateResource {
String associateName;
// other attributes...
// getter-setters...
}
现在,我有一个挑战,即每当ResourceDTO
填充任何resourceName时,associateName都是相同的。我该怎么做?
Ex: - 如果一个流正在填充ResourceDTO
,那么在“AssociateResource”变量列表中,“resourceName”应包含相同的名称。我该怎么做?任何帮助高度赞赏。
答案 0 :(得分:1)
在/home/ubuntu/Ytutor_Server/node_modules/mongodb-core/lib/topologies/shared.js:18
var nodejsversion = f('Node.js %s, %s', process.version, os.endianness());
^
TypeError: Object #<Object> has no method 'endianness'
at Object.<anonymous> (/home/ubuntu/Ytutor_Server/node_modules/mongodb-core/lib/topologies/shared.js:18:61)
at Module._compile (module.js:449:26)
at Object.Module._extensions..js (module.js:467:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:362:17)
at require (module.js:378:17)
at Object.<anonymous> (/home/ubuntu/Ytutor_Server/node_modules/mongodb-core/lib/connection/pool.js:11:12)
at Module._compile (module.js:449:26)
at Object.Module._extensions..js (module.js:467:10)
:
ResourceDTO