Core data 核心数据分配-值而不是地址

Core data 核心数据分配-值而不是地址,core-data,memory-address,assign,Core Data,Memory Address,Assign,我正在为3个objChordFun(核心数据对象)属性赋值。问题在于度属性。它的内容正在循环中的某个地方发布。发生了什么?如果能得到一些帮助,我将不胜感激 for (TonalScale *tonalScale in [TonalScale all]) { NSOrderedSet *tsScales = [NSOrderedSet orderedSetWithOrderedSet:tonalScale.scale]; Scale *tsScale

我正在为3个objChordFun(核心数据对象)属性赋值。问题在于度属性。它的内容正在循环中的某个地方发布。发生了什么?如果能得到一些帮助,我将不胜感激

    for (TonalScale *tonalScale in [TonalScale all]) {  
        NSOrderedSet *tsScales = [NSOrderedSet orderedSetWithOrderedSet:tonalScale.scale];  
        Scale *tsScale = [tsScales objectAtIndex:0];  
        NSOrderedSet *degrees = tsScale.degree;  
        for (int i=0; i<[tsScale.degree count]; i++) {  
            Degree *degree = [degrees objectAtIndex:i];  
            Scale *scale = [tsScales objectAtIndex:i];  
            NSSet *chords = [NSSet setWithSet:scale.chord];  
            for (Chord *chord in chords) {  
                for (Tonality *tlt in [Tonality all]) {  
                    objChordFun = [ChordFunction create];  
                    objChordFun.degree = degree;  
                    objChordFun.chord = chord;  
                    objChordFun.tonality = tlt;  
                }  
            }  
        }  
    }  
for(TonalScale*TonalScale in[TonalScale all]){
NSOrderedSet*TSSCALE=[NSOrderedSet orderedSetWithOrderedSet:tonalScale.scale];
Scale*tsScale=[tsScales objectAtIndex:0];
SensorDeredSet*度=tscale.degree;

对于(int i=0;它非常复杂。为什么有单数形式的有序集的名称?现在还不清楚
所有
创建
函数的来源以及它们的具体作用。你应该展示你的数据模型来澄清。标题是什么-“值而不是地址”-与问题相关?谢谢,Mundi。你是对的。我给几个对象分配了相同的值,而数据类声明了一对一的关系。愚蠢。我花了一周时间。